Posts

Showing posts from September, 2016

Setup secure Docker Registry with Nginx and SSL

Prerequisites Docker v1.12 installed. (though you could try it with lower version) Docker Compose v1.6 installed. apache2-utils are installed. Ubuntu (but it very similar for other distro). A domain name to run the docker registry. (a subdomain would work too). SSL certificate for the domain to run the docker registry on. Step 1: create docker-compose.yml Create a directory registry and under it create a docker-compose.yml . This docker-compose file create a registry container using the registry:2 image and also a front-end proxy using the nginx:1.10.1 image. The registry container is configured to expose it's port 5000 to other container that links to it (in this case, the proxy container can access the registry via that port) The proxy container is configured to listen to port 80 and 443 on the host. Other nginx configuration are stores under the conf.d directory that are mapped as volume. REGISTRY_HTTP_SECRET Set a secret text for the ...