docker-registry

command module
v0.0.0-...-fca68c0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 20, 2014 License: MIT Imports: 4 Imported by: 0

README

docker-registry

The dockboard's docker-registry is a Golang version what clone offical docker-registry, and we add user manage, UI and more features. We will add more backend storage services support like Qiniu, Aliyun OSS, Baidu Storage, Tencent COS and OpenStack Swift.

What's Registry?

A Registry is a hosted service containing repositories of images which responds to the Registry API.

What's FQIN?

A Fully Qualified Image Name (FQIN) can be made up of 3 parts:

[registry_hostname[:port]/][user_name/](repository_name[:version_tag])

version_tag defaults to latest, username and registry_hostname default to an empty string. When registry_hostname is an empty string, then docker push will push to index.docker.io:80.

Why image file named layer?

In Docker terminology, a read-only Layer is called an image. An image never changes.

How to build?

The project build with gopm.

Install gopm

go get -u github.com/gpmgo/gopm

Build commands:

gopm build 

How to Deploy?

How to Initlization MySQL Database?

INSERT INTO mysql.user(Host,User,Password) VALUES ('localhost', 'docker', password('docker'));
FLUSH PRIVILEGES;
CREATE DATABASE `registry` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
GRANT ALL PRIVILEGES ON registry.* TO docker@localhost IDENTIFIED BY 'docker';
FLUSH PRIVILEGES;

Nginx Conf

upstream index_upstream {
  server 127.0.0.1:9911;
}

server {
  listen 80;
  server_name index.dockboard.org;
  rewrite  ^/(.*)$  https://index.dockboard.org/$1  permanent;
}

server {
  listen 443;

  server_name index.dockboard.org;

  access_log /var/log/nginx/index-dockboard.log;
  error_log /var/log/nginx/index-dockboard-error.log;

  ssl on;
  ssl_certificate /etc/nginx/ssl/index.dockboard/ssl-bundle.crt;
  ssl_certificate_key /etc/nginx/ssl/index.dockboard/index_dockboard.key;

  client_max_body_size 1024m;
  chunked_transfer_encoding on;

  proxy_redirect     off;
  proxy_set_header   X-Real-IP $remote_addr;
  proxy_set_header   X-Forwarded-For $proxy_add_x_forwarded_for;
  proxy_set_header   X-Forwarded-Proto $scheme;
  proxy_set_header   Host $http_host;
  proxy_set_header   X-NginX-Proxy true;
  proxy_set_header   Connection "";
  proxy_http_version 1.1;

  location / {
    proxy_pass         http://index_upstream;
  }
}

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
Docker Push & Pull 执行 docker push 命令流程: 1.
Docker Push & Pull 执行 docker push 命令流程: 1.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL