1
0
forked from noxious/server

Attempt 9999

This commit is contained in:
Dennis Postma 2025-02-08 23:50:43 +01:00
parent 64c0d82d48
commit e7e187da7c
3 changed files with 53 additions and 0 deletions

0
certificates/acme.json Normal file
View File

View File

@ -34,6 +34,13 @@ services:
restart: unless-stopped restart: unless-stopped
networks: networks:
- app-network - app-network
labels:
- "traefik.enable=true"
- "traefik.http.routers.app.rule=Host(`${HOST}`)"
- "traefik.http.routers.app.entrypoints=websecure"
- "traefik.http.routers.app.tls=true"
- "traefik.http.routers.app.service=app"
- "traefik.http.services.app.loadbalancer.server.port=${PORT}"
mariadb: mariadb:
image: mariadb:lts image: mariadb:lts
@ -62,6 +69,19 @@ services:
networks: networks:
- app-network - app-network
traefik:
image: traefik:v3.3.3
ports:
- "80:80"
- "443:443"
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- ./traefik.yml:/etc/traefik/traefik.yml:ro
- ./certificates:/certificates
networks:
- app-network
restart: unless-stopped
networks: networks:
app-network: app-network:
driver: bridge driver: bridge

33
traefik.yml Normal file
View File

@ -0,0 +1,33 @@
entryPoints:
web:
address: ":80"
http:
redirections:
entryPoint:
to: websecure
scheme: https
websecure:
address: ":443"
http:
tls:
certResolver: letsencrypt
certificatesResolvers:
letsencrypt:
acme:
email: info@noxious.gg
storage: /certificates/acme.json
httpChallenge:
entryPoint: web
providers:
docker:
endpoint: "unix:///var/run/docker.sock"
exposedByDefault: false
network: app-network
log:
level: INFO
api:
dashboard: false