{"id":13584570,"url":"https://github.com/bubelov/traefik-letsencrypt-compose","last_synced_at":"2026-01-20T17:35:57.273Z","repository":{"id":46005234,"uuid":"217997654","full_name":"bubelov/traefik-letsencrypt-compose","owner":"bubelov","description":"Basic Traefik configuration which includes automatic Let’s Encrypt certificate management and password protected dashboard","archived":false,"fork":false,"pushed_at":"2021-11-21T09:07:54.000Z","size":20,"stargazers_count":102,"open_issues_count":1,"forks_count":32,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-01T20:37:59.716Z","etag":null,"topics":["docker","docker-compose","lets-encrypt","letsencrypt","traefik","traefik-v2"],"latest_commit_sha":null,"homepage":"","language":null,"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/bubelov.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}},"created_at":"2019-10-28T08:19:39.000Z","updated_at":"2025-02-16T17:34:50.000Z","dependencies_parsed_at":"2022-08-25T09:21:34.634Z","dependency_job_id":null,"html_url":"https://github.com/bubelov/traefik-letsencrypt-compose","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bubelov%2Ftraefik-letsencrypt-compose","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bubelov%2Ftraefik-letsencrypt-compose/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bubelov%2Ftraefik-letsencrypt-compose/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bubelov%2Ftraefik-letsencrypt-compose/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bubelov","download_url":"https://codeload.github.com/bubelov/traefik-letsencrypt-compose/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247578316,"owners_count":20961253,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["docker","docker-compose","lets-encrypt","letsencrypt","traefik","traefik-v2"],"created_at":"2024-08-01T15:04:20.835Z","updated_at":"2026-01-20T17:35:57.259Z","avatar_url":"https://github.com/bubelov.png","language":null,"funding_links":[],"categories":["Others"],"sub_categories":[],"readme":"# Traefik + Let’s Encrypt + Docker Compose \n\nThis guide shows you how to deploy your containers behind Traefik reverse-proxy. It will obtain and refresh HTTPS certificates automatically and it comes with password-protected Traefik dashboard. \n\n## Testing on Your Local Computer\n\n### Step 1: Make Sure You Have Required Dependencies\n\n- Git\n- Docker\n- Docker Compose\n\n#### Example Installation on Debian-based Systems:\n\n```\nsudo apt install git docker.io docker-compose\n```\n\n### Step 2: Clone the Repository\n\n```bash\ngit clone git@github.com:bubelov/traefik-letsencrypt-compose.git\ncd traefik-letsencrypt-compose\n```\n\n### Step 3: Add Environment Variables\n\n```bash\nnano .env\n```\n\n```bash\nDOMAIN=localhost\nEMAIL=admin@localhost\nCERT_RESOLVER=\nTRAEFIK_USER=admin\nTRAEFIK_PASSWORD_HASH=$2y$10$zi5n43jq9S63gBqSJwHTH.nCai2vB0SW/ABPGg2jSGmJBVRo0A.ni\n```\n\nNote that you should leave `CERT_RESOLVER` variable empty if you test your deployment locally. The password is `admin` and you might want to change it before deploying to production.\n\n### Step 4: Set Your Own Password\n\nIf you're curious about HTTP basic auth and how it can be used with Traefik, you can read [the full post](https://bubelov.com/blog/basic-auth-reverse-proxy/). Here is the excerpt and it assumes you already installed `htpasswd`:\n\n```bash\nhtpasswd -nBC 10 admin\n\nNew password:\nRe-type new password:\n\nadmin:$2y$10$zi5n43jq9S63gBqSJwHTH.nCai2vB0SW/ABPGg2jSGmJBVRo0A.ni\n```\n\nThe output has the following format: `username`:`password_hash`. The username doesn't have to be `admin`, feel free to change it (in the first line).\n\nYou can paste the username into the `TRAEFIK_USER` environment variable. The other part, `hashedPassword`, should be assigned to `TRAEFIK_PASSWORD_HASH`. Now you have your own `username`:`password` pair.\n\n### Step 5: Launch Your Deployment\n\n```bash\nsudo docker-compose up -d\n```\n\n### Step 6: Test Your Deployment\n\n```bash\ncurl --insecure https://localhost/\n```\n\nYou can also test it in the browser:\n\nhttps://localhost/\n\nhttps://traefik.localhost/\n\n## Deploying on a Public Server With Real Domain\n\nLet's say you have a domain `example.com` and it's DNS records point to your production server. Just repeat the local deployment steps, but don't forget to update `DOMAIN`, `EMAIL` and `CERT_RESOLVER` environment variables. In case of `example.com`, your `.env` file should have the following lines:\n\n```bash\nDOMAIN=example.com\nEMAIL=your@email.com\nCERT_RESOLVER=letsencrypt\n```\n\nSetting correct email is important because it allows Let’s Encrypt to contact you in case there are any present and future issues with your certificates.\n\nThat's it! Let me know if something was unclear to you or if you find any errors.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbubelov%2Ftraefik-letsencrypt-compose","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbubelov%2Ftraefik-letsencrypt-compose","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbubelov%2Ftraefik-letsencrypt-compose/lists"}