From f2aac212b0f8af9fc0741cc66e9e2bb11175f7b1 Mon Sep 17 00:00:00 2001 From: odweta Date: Sat, 12 Sep 2026 16:28:52 +0200 Subject: [PATCH] initial commit --- compose.yml | 65 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 compose.yml diff --git a/compose.yml b/compose.yml new file mode 100644 index 0000000..f7c053c --- /dev/null +++ b/compose.yml @@ -0,0 +1,65 @@ +services: + gitea: + image: docker.gitea.com/gitea:1.27.3 + container_name: gitea + restart: unless-stopped + depends_on: + db: + condition: service_healthy + environment: + USER_UID: "1000" + USER_GID: "1000" + + GITEA__database__DB_TYPE: postgres + GITEA__database__HOST: db:5432 + GITEA__database__NAME: gitea + GITEA__database__USER: gitea + GITEA__database__PASSWD: change-this-password + + GITEA__server__DOMAIN: localhost + GITEA__server__ROOT_URL: http://localhost:3003/ + GITEA__server__SSH_DOMAIN: localhost + GITEA__server__SSH_PORT: "2222" + + ports: + - "3003:3000" + - "2222:22" + + volumes: + - gitea-data:/data + - /etc/timezone:/etc/timezone:ro + - /etc/localtime:/etc/localtime:ro + + networks: + - gitea + + db: + image: postgres:16 + container_name: gitea-db + restart: unless-stopped + environment: + POSTGRES_DB: gitea + POSTGRES_USER: gitea + POSTGRES_PASSWORD: change-this-password + + ports: + - "5433:5432" + + volumes: + - postgres-data:/var/lib/postgresql/data + + healthcheck: + test: ["CMD-SHELL", "pg_isready -U gitea -d gitea"] + interval: 10s + timeout: 5s + retries: 5 + + networks: + - gitea + +networks: + gitea: + +volumes: + gitea-data: + postgres-data: