Fix dockerfile and add compose
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Melora Hugues 2023-10-19 18:33:46 +02:00
parent 3281d109f7
commit 4c3a0c648e
2 changed files with 25 additions and 0 deletions

View file

@ -9,6 +9,9 @@ RUN CGO_ENABLED=0 make build
FROM --platform=$TARGETPLATFORM alpine:latest
WORKDIR /root
COPY --from=builder go/src/git.faercol.me/polyculeconnect/build/polyculeconnect ./
ADD polyculeconnect/robots.txt /root/
ADD polyculeconnect/static /root/static/
ADD polyculeconnect/templates /root/templates/
VOLUME [ "/config" ]

22
docker-compose.yml Normal file
View file

@ -0,0 +1,22 @@
version: "3"
services:
polyculeconnect:
image: git.faercol.me/polyculeconnect/polyculeconnect:latest
container_name: polyculeconnect
volumes:
- "/data/polyculeconnect/config:/config"
restart: unless-stopped
networks:
- web
labels:
- "traefik.http.routers.polyculeconnect.rule=Host(`polyculeconnect.faercol.me`)"
- "traefik.http.routers.polyculeconnect.entrypoints=websecure"
- "traefik.http.routers.polyculeconnect.tls.certresolver=myResolver"
- "traefik.http.services.polyculeconnect.loadbalancer.server.port=5000"
- "traefik.enable=true"
networks:
web:
external:
true