1
0
mirror of https://github.com/vimagick/dockerfiles.git synced 2024-12-12 11:15:04 +02:00
dockerfiles/registry
2016-06-20 21:59:09 +08:00
..
docker-compose.yml add registry 2016-06-18 14:57:59 +08:00
README.md add dnsmasq-pxe 2016-06-20 21:59:09 +08:00

registry

Registry is the Docker toolset to pack, ship, store, and deliver content.

docker-compose.yml

registry:
  image: registry:2
  ports:
    - "5000:5000"
  volumes:
    - ./data:/var/lib/registry
    - ./certs:/certs
    - ./auth:/auth
  environment:
    - REGISTRY_HTTP_TLS_CERTIFICATE=/certs/registry.easypi.info.crt
    - REGISTRY_HTTP_TLS_KEY=/certs/registry.easypi.info.key
    - REGISTRY_AUTH=htpasswd
    - REGISTRY_AUTH_HTPASSWD_REALM=Registry Realm
    - REGISTRY_AUTH_HTPASSWD_PATH=/auth/htpasswd
  restart: always

up and running

$ docker-compose up -d
$ docker-compose exec registry bash
>>> htpasswd -Bbn username password >> /auth/htpasswd
>>> exit

$ docker pull alpine
$ docker tag alpine registry.easypi.info:5000/alpine

$ docker login -u username -p password easypi.info:5000
$ docker push registry.easypi.info:5000/alpine
$ docker pull registry.easypi.info:5000/alpine

read more