No description
Find a file
Jan Christian Grünhage e3b5864f34
All checks were successful
the build was successful
move most of this image over to docker.jcg.re/base-caddy, to make it integratable
2018-01-27 21:24:09 +01:00
root/etc feat: add more granular configuration via env vars 2017-12-15 03:35:21 +01:00
.drone.yml chore: removed version v0.10.4, as that one is not compatible with forwardproxy 2017-12-15 04:30:41 +01:00
Dockerfile move most of this image over to docker.jcg.re/base-caddy, to make it integratable 2018-01-27 21:24:09 +01:00
plugins.txt update caddy 2017-09-04 18:41:05 +02:00
README.md docs: fix missing newline causing wrong indention 2017-12-16 11:33:48 +01:00

docker.jcg.re/caddy

Build Status

Tags:

  • latest: latest stable version (currently 0.10.10)
  • v0.10.10: v0.10.10 of caddy
  • v0.10.9: v0.10.9 of caddy
  • v0.10.8: v0.10.8 of caddy
  • v0.10.7: v0.10.7 of caddy
  • v0.10.6: v0.10.6 of caddy
  • v0.10.5: v0.10.5 of caddy
  • v0.10.4: v0.10.4 of caddy

Build-time variables

Environment variables

  • UID: user id (default: 192)
  • GID: group id (default: 192)
  • DOMAIN: the domain that should be served (required for automatic tls)
  • EMAIL: the email address to use for let's encrypt (required for automatic tls)
  • USE_QUIC: set this to anything to enable experimental quic support (default: off)
  • LE_STAGING: use staging let's encrypt endpoint (default: off -> production)

Volumes

  • /etc/Caddyfile: webserver configuration (optional)
  • /var/www/: content to serve
  • /caddy: caddy will store it's certificates here (recommended if tls is active)

Ports

  • 80
  • 443

Basic docker-compose.yml example

Insecure example serving the contents of ./websiteon port 80:

version: '2'

services:
    caddy:
        image: docker.jcg.re/caddy
        container_name: caddy
        ports:
            - 80:80
        volumes:
            - ./website:/var/www/

Secure example serving the contents of ./websiteon https://example.com/ with an automatic redirect to https:

version: '2'

services:
    caddy:
        image: docker.jcg.re/caddy
        container_name: caddy
        ports:
            - 80:80
            - 443:443
        volumes:
            - ./website:/var/www/
        environment:
            - DOMAIN=example.com
            - EMAIL=you@example.com

Custom example doing whatever-the-fuck-you-want (take a look at https://caddyserver.com/docs):

version: '2'

services:
    caddy:
        image: docker.jcg.re/caddy
        container_name: caddy
        ports:
            - 80:80
            - 443:443
        volumes:
            - ./website:/var/www
            - ./Caddyfile:/etc/Caddyfile