Easy to use boilerplates for self-hosting and development
Explore the docs »
·
Report Bug
·
Request help or features
Table of Contents
Who does not love boilerplates? This will be the project where I collect and publish all kinds of boilerplates. My main focus for this project will be on providing good documentation and tested docker configurations for rapid deployment and development.
Unsure...
Maybe even try to get done with the syntax folder, adding helpful tips and tricks for future use
Download project, go into directory for what you would like to run and issue:
docker-compose up -d
- Docker
- Docker Compose
This allows you to use Traefik as your Reverse Proxy. This also adds the certificate from the certificate resolver you want. in this case production.
- Production = Lets Encrypt Production
- Staging = Lets Encrypt Staging
- Cloudflare = Cloudflare
labels:
- "traefik.enable=true"
- "traefik.http.routers.your-router-name.entrypoints=web, websecure"
- "traefik.http.routers.your-router-name.rule=Host(`servicename.example.com`)"
- "traefik.http.routers.your-router-name.tls=true"
- "traefik.http.routers.your-router-name.tls.certresolver=production"
To get everything working it also needs to be on the same network as traefik is controlling. This needs to be added to the services as well, I usually put it on the bottom of the docker-compose.yml file.
networks:
- web
networks:
web:
external: true
Add this to the labels for the traefik container
labels:
- "traefik.enable=true"
- "traefik.http.routers.traefik.entrypoints=web"
- "traefik.http.routers.traefik.rule=Host(`traefik-dashboard-internal.local.example.com`)"
- "traefik.http.middlewares.sslheader.headers.customrequestheaders.X-Forwarded-Proto=https"
- "traefik.http.routers.traefik-secure.entrypoints=websecure"
- "traefik.http.routers.traefik-secure.rule=Host(`traefik-dashboard-internal.local.example.com`)"
- "traefik.http.routers.traefik-secure.middlewares=traefik-auth"
- "traefik.http.routers.traefik-secure.tls=true"
- "traefik.http.routers.traefik-secure.tls.certresolver=cloudflare"
- "traefik.http.routers.traefik-secure.tls.domains[0].main=local.example.com"
- "traefik.http.routers.traefik-secure.tls.domains[0].sans=*.local.example.com"
- "traefik.http.routers.traefik-secure.service=api@internal"
Distributed under the MIT License. See LICENSE.txt
for more information.
Morten Haugstad - @codebarbarian
Project Link: https://github.com/codebarbarian/docker-boilerplates
- Most of the selfhosted software comes from https://linuxserver.io! They have a fantastic documentation at https://docs.linuxserver.io/