added deploy compose to repo to avoid volume mounts from workers
This commit is contained in:
63
backend/docker-compose.deploy.yml
Normal file
63
backend/docker-compose.deploy.yml
Normal file
@@ -0,0 +1,63 @@
|
||||
services:
|
||||
server:
|
||||
image: docker.gitea.com/gitea:latest
|
||||
container_name: gitea
|
||||
environment:
|
||||
- USER_UID=1020
|
||||
- USER_GID=1020
|
||||
- GITEA__service__DISABLE_REGISTRATION=true
|
||||
- GITEA__database__DB_TYPE=postgres
|
||||
- GITEA__database__HOST=db:5432
|
||||
- GITEA__database__NAME=gitea
|
||||
- GITEA__database__USER=gitea
|
||||
- GITEA__database__PASSWD=cams_very_special_GITEA_pwd_2o25
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- default
|
||||
volumes:
|
||||
- /home/git/gitea:/data
|
||||
- /home/git/.ssh/:/data/git/.ssh
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
ports:
|
||||
- "2222:22"
|
||||
expose:
|
||||
- "3000"
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
- "traefik.http.routers.gitea.rule=Host(`git.depaoli.id.au`)"
|
||||
- "traefik.http.routers.gitea.tls=true"
|
||||
- "traefik.http.routers.gitea.entrypoints=secureweb"
|
||||
- "traefik.http.services.gitea.loadbalancer.server.port=3000"
|
||||
- "traefik.http.routers.gitea.tls.certresolver=myresolver"
|
||||
- "traefik.docker.network=host"
|
||||
depends_on:
|
||||
- "db"
|
||||
runner:
|
||||
image: docker.io/gitea/act_runner:latest
|
||||
container_name: gitea_runner
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
- server
|
||||
networks:
|
||||
- default
|
||||
environment:
|
||||
GITEA_RUNNER_LABELS: "ubuntu-latest:docker://gitea-runner-base:ubuntu-node16"
|
||||
GITEA_INSTANCE_URL: "https://git.depaoli.id.au"
|
||||
GITEA_RUNNER_REGISTRATION_TOKEN: "JRrwF2HYSFKzFRVodBjiX4jIaMgZqrsaPgP9g6eh"
|
||||
GITEA_RUNNER_NAME: "gitea_runner"
|
||||
volumes:
|
||||
# needs docker sock to spin up children runners
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
- /srv/docker/container/gitea/runner:/data
|
||||
db:
|
||||
image: docker.io/library/postgres:14
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
- POSTGRES_USER=gitea
|
||||
- POSTGRES_PASSWORD=cams_very_special_GITEA_pwd_2o25
|
||||
- POSTGRES_DB=gitea
|
||||
networks:
|
||||
- default
|
||||
volumes:
|
||||
- /srv/docker/container/gitea/db:/var/lib/postgresql/data
|
||||
Reference in New Issue
Block a user