This project is forked from
abiosoft/caddy-docker. And I modified it to make it be more convenient to use.
Check MephistoMMM/caddy:builder for generating cross-platform Caddy binaries.
This image is built from source code. As such, it is subject to the project's Apache 2.0 license, but it neither contains nor is subject to the EULA for Caddy's official binary distributions.
Let's Encrypt Subscriber Agreement
Caddy may prompt to agree to Let's Encrypt Subscriber Agreement. This is configurable with
ACME_AGREE environment variable. Set it to true to agree.
This image is started by docker-compose, you have to install it first. If you had, run following script:
$ ./init.sh path/to/service_dir
This script will build some necessary docker images, create your service_dir if it doesn't exist, and finally run the caddy server in docker container.
Point your browser to
All of running configurations could be modified in docker-compose.yml, except Paths in container.
Paths in container
Let's Encrypt Auto SSL
Note that this does not work on local environments.
Use a valid domain and add email to your Caddyfile to avoid prompt at runtime.
mydomain.com with your domain and
email@example.com with your email.
mydomain.com tls firstname.lastname@example.org