{"id":21888736,"url":"https://github.com/sesto-dev/one-traefik-multiple-projects","last_synced_at":"2025-10-25T07:41:24.249Z","repository":{"id":259311374,"uuid":"871935416","full_name":"sesto-dev/one-traefik-multiple-projects","owner":"sesto-dev","description":"Repository for YouTube tutorial on how to use a single \"Traefik\" Docker container to host as many projects as you want in a single server.","archived":false,"fork":false,"pushed_at":"2024-10-24T22:19:40.000Z","size":2639,"stargazers_count":25,"open_issues_count":0,"forks_count":7,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-05-29T09:13:59.374Z","etag":null,"topics":["developer-tools","devops","docker","docker-compose","monitoring","reverse-proxy","self-hosted","traefik","traefik-v3"],"latest_commit_sha":null,"homepage":"https://www.youtube.com/watch?v=GBFbxtBZ51w","language":"TypeScript","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/sesto-dev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","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,"zenodo":null}},"created_at":"2024-10-13T11:09:43.000Z","updated_at":"2025-05-17T10:40:10.000Z","dependencies_parsed_at":"2024-10-27T09:03:57.426Z","dependency_job_id":null,"html_url":"https://github.com/sesto-dev/one-traefik-multiple-projects","commit_stats":null,"previous_names":["sesto-dev/one-traefik-multiple-projects"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/sesto-dev/one-traefik-multiple-projects","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sesto-dev%2Fone-traefik-multiple-projects","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sesto-dev%2Fone-traefik-multiple-projects/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sesto-dev%2Fone-traefik-multiple-projects/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sesto-dev%2Fone-traefik-multiple-projects/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sesto-dev","download_url":"https://codeload.github.com/sesto-dev/one-traefik-multiple-projects/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sesto-dev%2Fone-traefik-multiple-projects/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":280923471,"owners_count":26414234,"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","status":"online","status_checked_at":"2025-10-25T02:00:06.499Z","response_time":81,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["developer-tools","devops","docker","docker-compose","monitoring","reverse-proxy","self-hosted","traefik","traefik-v3"],"created_at":"2024-11-28T11:17:05.738Z","updated_at":"2025-10-25T07:41:24.201Z","avatar_url":"https://github.com/sesto-dev.png","language":"TypeScript","readme":"![Screenshot (11)](https://github.com/user-attachments/assets/4ea5c69b-9d50-4bfb-a08c-dc5523d2a7a1)\n\n# one-traefik-multiple-projects\n\nThis repo demonstrates how to use a single Traefik Docker container as a reverse proxy for multiple projects, each with different domains. Instead of manually installing and configuring a reverse proxy for a server, you can deploy this pre-configured Traefik container and easily add as many projects with as many domains as you need.\n\n```\nroot/\n├── traefik/\n│ ├── docker-compose.yml\n├── project-1/\n│ ├── docker-compose.yml\n├── project-2/\n│ ├── docker-compose.yml\n├── README.md\n└── ... (additional projects)\n```\n\n## Prerequisites\n\nBefore getting started, ensure you have the following installed on your system:\n\n- Docker - [How to install Docker](https://docs.docker.com/get-docker/) (version 20.10.0 or higher)\n- Docker Compose - [How to install Docker Compose](https://docs.docker.com/compose/install/) (version 1.27.0 or higher)\n- Git - [How to Install Git on Ubuntu](https://www.digitalocean.com/community/tutorials/how-to-install-git-on-ubuntu)\n- A registered domain name pointed to your server's IP address - [What are DNS Records?](https://www.cloudflare.com/learning/dns/dns-records/) - [What is a DNS A Record?](https://www.cloudflare.com/learning/dns/dns-records/dns-a-record/)\n- Open ports `80` and `443` on your server - [How to Open a Port on a Linux Server Using UFW?](https://www.digitalocean.com/community/tutorials/opening-a-port-on-linux)\n\n## Getting Started\n\nFollow these steps to set up the Traefik reverse proxy and deploy multiple projects.\n\n### 1. Clone the Repository\n\n```bash\ngit clone https://github.com/sesto-dev/one-traefik-multiple-projects.git\n```\n\n### 2. Create Docker Network\n\nTraefik and the projects need to communicate over a shared Docker network.\n\n```bash\ndocker network create traefik-public\n```\n\n### 3. Traefik Docker Container\n\nSet up the necessary environment variables for Traefik and each project.\n\n```bash\ncd one-traefik-multiple-projects/traefik\n```\n\nCreate a `.env` file inside the `traefik` directory:\n\n```bash\ncp .env.example .env\nnano .env\n```\n\nEdit the `.env` file to set your domain and other necessary variables.\n\n```bash\nUSERNAME=your_admin_username\nPASSWORD=your_admin_password\nDOMAIN=yourdomain.com\nACME_EMAIL=youremail@domain.com\n```\n\n**Note:** To generate and set the hashed password in one command for Traefik's HTTP Basic Auth, you can use the following command:\n\n```bash\nexport HASHED_PASSWORD=$(openssl passwd -apr1 $PASSWORD)\n```\n\nThen spin up your Traefik container:\n\n```bash\ndocker compose up -d\n```\n\n### 4. Project Docker Containers\n\nFor each project, create a `.env` file based on the provided examples and enter the DOMAIN for that project.\n\n```bash\ncd ../project-1\ncp .env.example .env\nnano .env`\n```\n\n```bash\nDOMAIN=project1.yourdomain.com\n```\n\nThen spin up the project container:\n\n```bash\ndocker compose up -d\n```\n\nRepeat for project-2.\n\n### 5. Verify the Setup\n\nOpen your browser and navigate to the domains you've configured. You should see the projects running correctly. You can also visit Traefik's dashboard at `https://traefik.yourdomain.com`.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsesto-dev%2Fone-traefik-multiple-projects","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsesto-dev%2Fone-traefik-multiple-projects","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsesto-dev%2Fone-traefik-multiple-projects/lists"}