mirror of
https://github.com/acedanger/docker.git
synced 2025-12-06 01:10:11 -08:00
Add healthcheck and labels to Gitea services in docker-compose; add runner for CICD
This commit is contained in:
@@ -22,6 +22,19 @@ services:
|
|||||||
- ${GITEA_SSH_PORT:-2229}:22
|
- ${GITEA_SSH_PORT:-2229}:22
|
||||||
depends_on:
|
depends_on:
|
||||||
- db
|
- db
|
||||||
|
labels:
|
||||||
|
- diun.enable=true
|
||||||
|
healthcheck:
|
||||||
|
test:
|
||||||
|
- CMD
|
||||||
|
- curl
|
||||||
|
- -f
|
||||||
|
- http://localhost
|
||||||
|
interval: 10s
|
||||||
|
retries: 3
|
||||||
|
start_period: 30s
|
||||||
|
timeout: 10s
|
||||||
|
|
||||||
db:
|
db:
|
||||||
image: docker.io/library/postgres:14
|
image: docker.io/library/postgres:14
|
||||||
restart: always
|
restart: always
|
||||||
@@ -33,11 +46,30 @@ services:
|
|||||||
- gitea
|
- gitea
|
||||||
volumes:
|
volumes:
|
||||||
- postgres:/var/lib/postgresql/data
|
- postgres:/var/lib/postgresql/data
|
||||||
|
|
||||||
|
runner:
|
||||||
|
image: gitea/act_runner:latest
|
||||||
|
container_name: gitea-runner
|
||||||
|
restart: always
|
||||||
|
networks:
|
||||||
|
- gitea
|
||||||
|
volumes:
|
||||||
|
- runner:/data
|
||||||
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
|
environment:
|
||||||
|
- GITEA_INSTANCE_URL=http://server:3000
|
||||||
|
- GITEA_RUNNER_REGISTRATION_TOKEN=${GITEA_RUNNER_REGISTRATION_TOKEN}
|
||||||
|
- GITEA_RUNNER_NAME=docker-runner
|
||||||
|
depends_on:
|
||||||
|
- server
|
||||||
|
labels:
|
||||||
|
- diun.enable=true
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
gitea:
|
gitea:
|
||||||
external: false
|
external: false
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
gitea:
|
gitea:
|
||||||
driver: local
|
|
||||||
postgres:
|
postgres:
|
||||||
driver: local
|
runner:
|
||||||
|
|||||||
Reference in New Issue
Block a user