{"id":42311863,"url":"https://github.com/fedorov-xyz/enhanced-nginx","last_synced_at":"2026-01-27T11:36:01.784Z","repository":{"id":245128558,"uuid":"817293451","full_name":"fedorov-xyz/enhanced-nginx","owner":"fedorov-xyz","description":"Nginx Docker container with standalone certbot and automatic update of Cloudflare IP address ranges","archived":false,"fork":false,"pushed_at":"2024-06-20T16:35:53.000Z","size":19,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-06-22T02:25:35.575Z","etag":null,"topics":["certbot","cloudflare","docker","letsencrypt","nginx","nginx-proxy"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fedorov-xyz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-06-19T12:08:11.000Z","updated_at":"2024-06-20T16:35:39.000Z","dependencies_parsed_at":"2024-06-20T01:11:30.314Z","dependency_job_id":null,"html_url":"https://github.com/fedorov-xyz/enhanced-nginx","commit_stats":null,"previous_names":["fedorov-xyz/enhanced-nginx"],"tags_count":8,"template":false,"template_full_name":null,"purl":"pkg:github/fedorov-xyz/enhanced-nginx","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fedorov-xyz%2Fenhanced-nginx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fedorov-xyz%2Fenhanced-nginx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fedorov-xyz%2Fenhanced-nginx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fedorov-xyz%2Fenhanced-nginx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fedorov-xyz","download_url":"https://codeload.github.com/fedorov-xyz/enhanced-nginx/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fedorov-xyz%2Fenhanced-nginx/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28812454,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-27T07:41:26.337Z","status":"ssl_error","status_checked_at":"2026-01-27T07:41:08.776Z","response_time":168,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["certbot","cloudflare","docker","letsencrypt","nginx","nginx-proxy"],"created_at":"2026-01-27T11:36:01.088Z","updated_at":"2026-01-27T11:36:01.778Z","avatar_url":"https://github.com/fedorov-xyz.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Enhanced Nginx\n\n\u003e Documentation in progress\n\nThe script to generate the config for Cloudflare is taken from here: https://github.com/ergin/nginx-cloudflare-real-ip\n\nNginx Docker container with standalone certbot and automatic update of Cloudflare IP address ranges.\n\n## How it works\n\nInstead of agonizing with certbot + nginx + well-known/acme-challenge, let's just let certbot do its job in standalone mode.\n\nWhen the container is started for the first time, certbot will bring up its server, issue and fail certificates. And then at the very end nginx will start up.\n\nWhen restarting the container, certbot will check the existing certificate for expiration, and if the expiration is ok, it will just not do anything, nginx will start right away.\n\n## Usage\n\n1. Specify 2 volumes for nginx and letsencrypt \n2. Mount your site config to container. You can mount multiple sites\n\nYou should use the following lines in your nginx config for the site. `REPLACEMENT_CERT_NAME` will be replaced by the name of the certificate you pass to the container.\n\n```nginx configuration\n  ssl_certificate         /etc/letsencrypt/live/REPLACEMENT_CERT_NAME/fullchain.pem;\n  ssl_certificate_key     /etc/letsencrypt/live/REPLACEMENT_CERT_NAME/privkey.pem;\n  ssl_trusted_certificate /etc/letsencrypt/live/REPLACEMENT_CERT_NAME/chain.pem;\n```\n\nIf you want to serve multiple domains within a container, list their domains in the `SITE_DOMAINS` environment variable. A common certificate will be issued for them.\n\n### Directories for your configs\n\nYou can include your configuration via mounting configs to container's special paths. It could be virtual server blocks or additional `http` section configuration (such as `log_format` directive). \n\n| Path                    | Description                                              |\n|-------------------------|----------------------------------------------------------|\n| `/nginx-config/conf/`   | Will be included into `http` section of the Nginx config |\n| `/nginx-config/stream/` | -\u003e `stream` section                                      |\n\n### Example\n\nFor Docker Compose:\n\n```yaml filename=\"docker-compose.yml\"\nvolumes:\n  nginx_data:\n  letsencrypt_data:\n\nservices:\n  nginx:\n    image: ghcr.io/fedorov-xyz/enhanced-nginx:latest\n    ports:\n      - 80:80\n      - 443:443\n    volumes:\n      - nginx_data:/etc/nginx/data\n      - letsencrypt_data:/etc/letsencrypt\n      - ./example.com.conf:/nginx-config/conf/example.com.conf\n    environment:\n      - TZ=UTC\n      - SITE_DOMAINS=example.com,staging.example.com\n      - CERT_NAME=example.com\n      - CERTBOT_EMAIL=your@email.com\n      - CERTBOT_TEST_CERT=true\n```\n\n## Environment variables list\n\n| Variable             | Requirded | Description                                                   |\n|----------------------|-----------|---------------------------------------------------------------|\n| `TZ`                 |           | Timezone                                                      |\n| `SITE_DOMAINS`       | yes       | Сomma-separated list of domains for Let's Encrypt certificate |\n| `CERT_NAME`          | yes       | Certificate name.                                             |\n| `CERTBOT_EMAIL`      | yes       | Email for Let's Encrypt.                                      |\n| `CERTBOT_TEST_CERT`  |           | Pass `true` for test certificates.                            |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffedorov-xyz%2Fenhanced-nginx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffedorov-xyz%2Fenhanced-nginx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffedorov-xyz%2Fenhanced-nginx/lists"}