mirror of
https://github.com/vimagick/dockerfiles.git
synced 2024-11-24 08:52:31 +02:00
add registry
This commit is contained in:
parent
7c2d385102
commit
c5d53aa09f
@ -152,6 +152,7 @@ A collection of delicious docker recipes.
|
||||
- [x] neo4j
|
||||
- [x] owncloud
|
||||
- [x] phpmyadmin
|
||||
- [x] registry
|
||||
- [x] rocket.chat
|
||||
- [x] scrapinghub/splash
|
||||
- [ ] selenium
|
||||
|
42
registry/README.md
Normal file
42
registry/README.md
Normal file
@ -0,0 +1,42 @@
|
||||
registry
|
||||
========
|
||||
|
||||
[Registry][1] is the Docker toolset to pack, ship, store, and deliver content.
|
||||
|
||||
## docker-compose.yml
|
||||
|
||||
```yaml
|
||||
registry:
|
||||
image: registry:2
|
||||
ports:
|
||||
- "5000:5000"
|
||||
volumes:
|
||||
- ./data:/var/lib/registry
|
||||
- ./certs:/certs
|
||||
- ./auth:/auth
|
||||
environment:
|
||||
- REGISTRY_HTTP_TLS_CERTIFICATE=/certs/easypi.info.crt
|
||||
- REGISTRY_HTTP_TLS_KEY=/certs/easypi.info.key
|
||||
- REGISTRY_AUTH=htpasswd
|
||||
- REGISTRY_AUTH_HTPASSWD_REALM=Registry Realm
|
||||
- REGISTRY_AUTH_HTPASSWD_PATH=/auth/htpasswd
|
||||
restart: always
|
||||
```
|
||||
|
||||
## up and running
|
||||
|
||||
```bash
|
||||
$ docker-compose up -d
|
||||
$ docker-compose exec registry bash
|
||||
>>> htpasswd -Bbn username password >> /auth/htpasswd
|
||||
>>> exit
|
||||
|
||||
$ docker pull alpine
|
||||
$ docker tag alpine easypi.info:5000/alpine
|
||||
|
||||
$ docker login -u username -p password easypi.info:5000
|
||||
$ docker push easypi.info:5000/alpine
|
||||
$ docker pull easypi.info:5000/alpine
|
||||
```
|
||||
|
||||
[1]: https://github.com/docker/distribution
|
15
registry/docker-compose.yml
Normal file
15
registry/docker-compose.yml
Normal file
@ -0,0 +1,15 @@
|
||||
registry:
|
||||
image: registry:2
|
||||
ports:
|
||||
- "5000:5000"
|
||||
volumes:
|
||||
- ./data:/var/lib/registry
|
||||
- ./certs:/certs
|
||||
- ./auth:/auth
|
||||
environment:
|
||||
- REGISTRY_HTTP_TLS_CERTIFICATE=/certs/easypi.info.crt
|
||||
- REGISTRY_HTTP_TLS_KEY=/certs/easypi.info.key
|
||||
- REGISTRY_AUTH=htpasswd
|
||||
- REGISTRY_AUTH_HTPASSWD_REALM=Registry Realm
|
||||
- REGISTRY_AUTH_HTPASSWD_PATH=/auth/htpasswd
|
||||
restart: always
|
Loading…
Reference in New Issue
Block a user