artifactkeeper.yaml
· 1.3 KiB · YAML
Raw
services:
postgres:
image: postgres:15-alpine
container_name: ak-postgres
environment:
POSTGRES_USER: ak_user
POSTGRES_PASSWORD: ak_password
POSTGRES_DB: artifact_keeper
volumes:
- ./pg_data:/var/lib/postgresql/data
healthcheck:
test:
- CMD-SHELL
- pg_isready -U ak_user -d artifact_keeper
interval: 5s
timeout: 5s
retries: 5
backend:
image: artifactkeeper/backend:latest
container_name: ak-backend
user: "root"
# Переносим порт бэкенда на 8081, чтобы освободить 8080 для фронтенда
ports:
- 8081:8080
environment:
- DATABASE_URL=postgres://ak_user:ak_password@postgres:5432/artifact_keeper
- JWT_SECRET=ChangeMeToAVeryLongAndSecureRandomString123!
- ADMIN_PASSWORD=DefaultAdminPassword123!
- STORAGE_BACKEND=filesystem
- STORAGE_PATH=/data/storage
- SITE_ADDRESS=http://127.0.0.1:8080
volumes:
- ./ak_storage:/data/storage
depends_on:
postgres:
condition: service_healthy
healthcheck:
disable: true
frontend:
image: artifactkeeper/web:latest
container_name: ak-frontend
ports:
- 8080:3000
environment:
- API_URL=http://127.0.0.1:8081
depends_on:
- backend
networks: {}
| 1 | services: |
| 2 | postgres: |
| 3 | image: postgres:15-alpine |
| 4 | container_name: ak-postgres |
| 5 | environment: |
| 6 | POSTGRES_USER: ak_user |
| 7 | POSTGRES_PASSWORD: ak_password |
| 8 | POSTGRES_DB: artifact_keeper |
| 9 | volumes: |
| 10 | - ./pg_data:/var/lib/postgresql/data |
| 11 | healthcheck: |
| 12 | test: |
| 13 | - CMD-SHELL |
| 14 | - pg_isready -U ak_user -d artifact_keeper |
| 15 | interval: 5s |
| 16 | timeout: 5s |
| 17 | retries: 5 |
| 18 | backend: |
| 19 | image: artifactkeeper/backend:latest |
| 20 | container_name: ak-backend |
| 21 | user: "root" |
| 22 | # Переносим порт бэкенда на 8081, чтобы освободить 8080 для фронтенда |
| 23 | ports: |
| 24 | - 8081:8080 |
| 25 | environment: |
| 26 | - DATABASE_URL=postgres://ak_user:ak_password@postgres:5432/artifact_keeper |
| 27 | - JWT_SECRET=ChangeMeToAVeryLongAndSecureRandomString123! |
| 28 | - ADMIN_PASSWORD=DefaultAdminPassword123! |
| 29 | - STORAGE_BACKEND=filesystem |
| 30 | - STORAGE_PATH=/data/storage |
| 31 | - SITE_ADDRESS=http://127.0.0.1:8080 |
| 32 | volumes: |
| 33 | - ./ak_storage:/data/storage |
| 34 | depends_on: |
| 35 | postgres: |
| 36 | condition: service_healthy |
| 37 | healthcheck: |
| 38 | disable: true |
| 39 | |
| 40 | frontend: |
| 41 | image: artifactkeeper/web:latest |
| 42 | container_name: ak-frontend |
| 43 | ports: |
| 44 | - 8080:3000 |
| 45 | environment: |
| 46 | - API_URL=http://127.0.0.1:8081 |
| 47 | depends_on: |
| 48 | - backend |
| 49 | networks: {} |
| 50 |