Sign inSign up

kitspace/nginx-certbot-plugin

By kitspace

•Updated almost 7 years ago

Runs Nginx and automatically installs letsencrypt certificates

Image
0

1.8K

kitspace/nginx-certbot-plugin repository overview

⁠Nginx, Certbot and the Certbot Nginx Plugin

Source: https://github.com/kitspace/docker-nginx-certbot-plugin⁠

Docker container that runs Nginx⁠ and requests and installs letsencrypt https certificates through Certbot⁠.

This is mainly just the upstream Nginx Alpine container⁠ but runs the simple script in ./command⁠ that requests and installs a certificate through the Certbot Nginx plugin⁠ (a.k.a certbot --nginx) if you set variables:

RUN_CERTBOT=true
CERTBOT_DOMAINS=example.com,www.example.com
[email protected]

This is inspired by/partially copied from staticfloat/docker-nginx-certbot⁠ but scripting is vastly simplified by just relying on cerbot --nginx.

⁠Usage

In a development/testing environment you can simply leave RUN_CERTBOT unset or RUN_CERTBOT=false and you can test your Nginx config without https locally.

The script in the container will attempt certificate renewal every 7 days.

⁠Docker
docker run -e 'RUN_CERTBOT=true' -e 'CERTBOT_DOMAINS=example.com,www.example.com' -e '[email protected]' kitspace/nginx-certbot-plugin
⁠Docker Compose
services:
  nginx:
    image: kitspace/nginx-certbot-plugin 
    environment:
      - RUN_CERTBOT=true
      - CERTBOT_DOMAINS=example.com,www.example.com
      - [email protected]

Tag summary

Content type

Image

Digest

Size

31.5 MB

Last updated

almost 7 years ago

docker pull kitspace/nginx-certbot-plugin