Skip to content
trydirectPublic

About

NGINX with Certbot and fastcgi_cache support

Topics

Resources

Stars

3 stars

Watchers

3 watching

Forks

Repository files navigation

CI Docker Stars Docker Pulls

NGINX with Certbot

Overview

Custom Nginx docker image files: NGINX + Supervisord + Certbot (fastcgi_cache ready).

Stack includes

  • NGINX (official nginx image base)
  • Supervisord (nginx + cron)
  • Certbot (python3-certbot-nginx) with a letsencrypt-auto compatibility shim

Base image / versions

The nginx version is a build argument (default 1.31.9, the fixed release for CVE-2026-123007 / NGINX2Root):

docker build --build-arg NGINX_VERSION=1.31.9 -t trydirect/nginx:latest .

Usage

docker compose up -d
# or
docker run -d -p 80:80 -p 443:443 trydirect/nginx:latest

nginx runs under supervisord; workers run as www-data, pid/temp paths live under /tmp. Mount site configs into /etc/nginx/conf.d/ and certificates into /etc/letsencrypt.

Certbot

Certbot comes from Debian (python3-certbot-nginx):

docker exec <container> certbot --nginx -d example.com -d www.example.com

/opt/letsencrypt/letsencrypt-auto is kept as a thin shim that forwards to certbot for backwards compatibility with older cron jobs and docs (the historical certbot-auto script was retired by EFF and no longer works).

Development

docker compose build
docker compose up -d
python3 tests.py    # smoke tests (needs: pip install docker)
docker compose down

CI builds, lints (hadolint) and runs the smoke tests on every push; image publishing to Docker Hub is a manual workflow_dispatch action.

About

NGINX with Certbot and fastcgi_cache support

Topics

Resources

Stars

3 stars

Watchers

3 watching

Forks

Releases

Packages

Contributors

Languages