Skip to content

This is a repo for a Docker Compose to deploy Portainer behind Caddy with automatic TLS resolver via LetsEncrypt on a Docker Swarm.

Notifications You must be signed in to change notification settings

digitoolmedia/dm-docker-pocadec

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

POCADEC Stack

Pocadec stands for: POrtainer CADdy letsEnCrypt

(ikr? 🙄)

Start the stack via docker stack deploy -c pocadec.yml pocadec

About this read me

This is going to be a nice readme and basic doco for the deployment of this stack on a docker swarm, with FAQ regarding some workaround and caveats.

Create required networks

docker network create -d overlay agent_network
docker network create -d overlay --attachable caddy-public

http cache

Firstly build the custom image using caddy.dockerfile, then set it in the main swarm-pocadec.yml and uncomment the last two caddy labels.

docker build -t cdp-custom:2.7.4-alpine . -f caddy.dockerfile --build-arg="CADDY_VERSION=2.7.4"

caddy-dns

In the event of requiring a dns resolver for using wildcards, a custom Caddy image build is required with the following structure added.

build  --with github.com/caddy-dns/REPOSITORY_NAME

check current caddyfile.autosave

docker exec $(docker ps -qf "name=^pocadec_caddy") sh -c "cat /config/caddy/Caddyfile.autosave"

ENV List

ACME_USER_EMAIL
DNS_PROVIDER DNS_API_PROVIDER DNS_API_KEY
HOSTNAME
WILDCARD_MAIN_DOMAIN
WILDCARD_SANS_DOMAIN
TRAEFIK_DOMAIN
TRAEFIK_BASICAUTH_USERS
PORTAINER_DOMAIN
EDGE_DOMAIN

To-Do

  • doco
  • env variables definition
  • caveats
  • FAQ

About

This is a repo for a Docker Compose to deploy Portainer behind Caddy with automatic TLS resolver via LetsEncrypt on a Docker Swarm.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Dockerfile 100.0%