docker-compose.yml
· 1.3 KiB · YAML
Неформатований
networks:
npm-net:
name: npm-net
external: true
services:
forgejo:
image: codeberg.org/forgejo/forgejo:13
container_name: forgejo
environment:
- USER_UID=1000
- USER_GID=1000
- GITEA__database__DB_TYPE=postgres
- GITEA__database__HOST=gitea-db:5432
- GITEA__database__NAME=gitea
- GITEA__database__USER=gitea
- GITEA__database__PASSWD=llheeAoGyTGwVHiTryfB3oWDP
- GITEA__server__DOMAIN=git.emanuelegori.uno
#- GITEA__server__SSH_PORT=2222
- GITEA__server__ROOT_URL=https://git.emanuelegori.uno
restart: unless-stopped
networks:
- npm-net
volumes:
- ./gitea-data:/data
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
#ports:
# - "3000:3000"
# - "2222:22"
depends_on:
gitea-db:
condition: service_healthy
gitea-db:
image: postgres:16-alpine
container_name: gitea-db
restart: unless-stopped
environment:
- POSTGRES_USER=gitea
- POSTGRES_PASSWORD=llheeAoGyTGwVHiTryfB3oWDP
- POSTGRES_DB=gitea
networks:
- npm-net
volumes:
- ./gitea-db:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U gitea"]
interval: 10s
timeout: 5s
retries: 5
| 1 | networks: |
| 2 | npm-net: |
| 3 | name: npm-net |
| 4 | external: true |
| 5 | |
| 6 | services: |
| 7 | forgejo: |
| 8 | image: codeberg.org/forgejo/forgejo:13 |
| 9 | container_name: forgejo |
| 10 | environment: |
| 11 | - USER_UID=1000 |
| 12 | - USER_GID=1000 |
| 13 | - GITEA__database__DB_TYPE=postgres |
| 14 | - GITEA__database__HOST=gitea-db:5432 |
| 15 | - GITEA__database__NAME=gitea |
| 16 | - GITEA__database__USER=gitea |
| 17 | - GITEA__database__PASSWD=llheeAoGyTGwVHiTryfB3oWDP |
| 18 | - GITEA__server__DOMAIN=git.emanuelegori.uno |
| 19 | #- GITEA__server__SSH_PORT=2222 |
| 20 | - GITEA__server__ROOT_URL=https://git.emanuelegori.uno |
| 21 | restart: unless-stopped |
| 22 | networks: |
| 23 | - npm-net |
| 24 | volumes: |
| 25 | - ./gitea-data:/data |
| 26 | - /etc/timezone:/etc/timezone:ro |
| 27 | - /etc/localtime:/etc/localtime:ro |
| 28 | #ports: |
| 29 | # - "3000:3000" |
| 30 | # - "2222:22" |
| 31 | depends_on: |
| 32 | gitea-db: |
| 33 | condition: service_healthy |
| 34 | |
| 35 | gitea-db: |
| 36 | image: postgres:16-alpine |
| 37 | container_name: gitea-db |
| 38 | restart: unless-stopped |
| 39 | environment: |
| 40 | - POSTGRES_USER=gitea |
| 41 | - POSTGRES_PASSWORD=llheeAoGyTGwVHiTryfB3oWDP |
| 42 | - POSTGRES_DB=gitea |
| 43 | networks: |
| 44 | - npm-net |
| 45 | volumes: |
| 46 | - ./gitea-db:/var/lib/postgresql/data |
| 47 | healthcheck: |
| 48 | test: ["CMD-SHELL", "pg_isready -U gitea"] |
| 49 | interval: 10s |
| 50 | timeout: 5s |
| 51 | retries: 5 |