Sign inSign up

clevyr/caddy

By clevyr

Updated over 1 year ago

Image
0

10K+

clevyr/caddy repository overview

docker-caddy

Docker Build

Preconfigured Caddy container for local https development environments.

Pull Command

docker pull ghcr.io/clevyr/caddy

Config

VariableDescriptionDefault
SITE_ADDRESSAddress used to serve requests.clevyr.run
APP_ADDRESSUpstream for https://$SITE_ADDRESS/* and wildcard subdomains.app
API_ADDRESSUpstream for https://api.$SITE_ADDRESS/*.app
HOT_ADDRESSUpstream for https://hot.$SITE_ADDRESS/.hot:5173
MAIL_ADDRESSUpstream for https://mail.$SITE_ADDRESS/*.mail
WS_ADDRESSUpstream for https://ws.$SITE_ADDRESS/*.websocket-server:6001
SOCKETIO_ADDRESSUpstream for https://$SITE_ADDRESS/socket.io/*app
LOG_OUTPUTLog output module. See Caddy log output modules.discard

Usage

Adding to an app

Add this Docker image to an app's docker-compose.yml with a volume bind in a global location. This allows for the root CA to persist between applications.

proxy:
  image: ghcr.io/clevyr/caddy
  ports:
    - 80:80
    - 443:443
  restart: unless-stopped
  volumes:
    - ~/.config/caddy:/data
Trusting the root CA

Trusting the root CA is safe as long as the file is never shared. This will make sites work with a valid https certificate which is unique for each machine.
To trust the local root CA on macOS, run the following command:

security add-trusted-cert -r trustRoot -k ~/Library/Keychains/login.keychain-db ~/.config/caddy/caddy/pki/authorities/local/root.crt

Tag summary

Content type

Image

Digest

sha256:ae287a9af

Size

17.5 MB

Last updated

over 1 year ago

docker pull clevyr/caddy