Moved repositories and databases to local directory

This commit is contained in:
2026-08-28 11:58:12 +03:00
parent 87eb38ad81
commit 61b322332f
4 changed files with 105 additions and 0 deletions
+22
View File
@@ -1,8 +1,28 @@
services:
init-permissions:
image: alpine:3.21
container_name: git-server-init-permissions
restart: "no"
environment:
USER_UID: ${USER_UID:-1000}
USER_GID: ${USER_GID:-1000}
volumes:
- ./docker/gitea:/gitea
- ./docker/postgres:/postgres
command:
- /bin/sh
- -ec
- |
chown -R "$${USER_UID}:$${USER_GID}" /gitea
chown -R 70:70 /postgres
db:
image: postgres:16-alpine
container_name: git-server-db
restart: unless-stopped
depends_on:
init-permissions:
condition: service_completed_successfully
environment:
POSTGRES_USER: ${POSTGRES_USER:-gitea}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-change-me-in-env}
@@ -22,6 +42,8 @@ services:
container_name: git-server
restart: unless-stopped
depends_on:
init-permissions:
condition: service_completed_successfully
db:
condition: service_healthy
environment: