Docker container for Caddy
Clone or download
Pull request Compare This branch is 12 commits ahead, 92 commits behind abiosoft:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

Caddy for linux arm7 & amd64

A Docker image for Caddy that will let you to serve http or https with Let's Encrypt certificate autogenerated. This image includes the git plugin. Plugins can be configured via the PLUGIN file at build time. Forked from abiosoft/caddy-docker initially to provide an arm compatible container, now also compatible with amd64 architecture (thanks to its Multi-Arch base image)


Latest Enhancements

Getting Started

This is a simple usage for testing proposes.

$ docker run -d -p 2015:2015 elswork/arm-caddy:latest

Point your browser to

My Real Usage Example

In order everyone could take full advantages of the usage of this docker container, I'll describe my own real usage setup.

$ docker run -d \
    --name myarm-caddy \
    -p 80:80 -p 443:443 \
    -v /var/www/html:/srv \
    -v $HOME/Caddyfile/https:/etc/Caddyfile \
    -v $HOME/.caddy:/root/.caddy \

--name myarm-caddy This is absolutely optional, it helps to me to easily identify and operate the container after the first execution.

$ docker start myarm-caddy
$ docker stop myarm-caddy
$ docker rm myarm-caddy

-p 80:80 -p 443:443 Caddy will serve https by default.

-v /var/www/html:/srv /var/www/html is the local folder where I have the files to serve. I mount in the container folder that Caddy use to serve files.

-v $HOME/Caddyfile/https:/etc/Caddyfile $HOME/Caddyfile/https is my Caddy configuration file., {
log stdout
errors stdout

-v $HOME/.caddy:/root/.caddy I mount the folder where I will store the Let's Encrypt certificates that will be generated automatically the first time the container run, in order to prevent regenerating them each time.

Let's Encrypt Auto SSL

Note that this does not work on local environments.

You must use a valid domain properly configured to point your docker server and add email to your Caddyfile to avoid prompt at runtime.