Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/alexanderjulo/caddy-gen

Automatically generates Caddyfile for running containers
https://github.com/alexanderjulo/caddy-gen

Last synced: 5 days ago
JSON representation

Automatically generates Caddyfile for running containers

Awesome Lists containing this project

README

        

# caddy-gen

Automatically generate a central Caddyfile for many containers.

First off, start the generator container:

docker run -e LETSENCRYPT_EMAIL= -v :/etc/caddy -v /var/run/docker.sock:/var/run/docker.sock alexanderjulo/caddy-gen

Then start whatever service you want to be proxied (which has to either expose or publish the port you want to be exposed to the open):

docker run -e VIRTUAL_HOST= -p dockercloud/hello-world

Then start a caddy container that will handle all your outbound traffic:

docker run -l autocaddy=1 -v :/var/www/html/Caddyfile:ro -v sslcerts:/etc/ssl/certs -p 80:80 -p 443:443 joshix/caddy