onasty/docker-compose.yml(view raw)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 |
services:
runtime:
image: onasty:runtime
build:
context: .
dockerfile: runtime.Dockerfile
depends_on:
- builder
builder:
image: onasty:builder
build:
context: .
dockerfile: builder.Dockerfile
core:
image: onasty:core
container_name: onasty-core
build:
context: .
dockerfile: Dockerfile
env_file: .env
ports:
- 8000:8000
- 8001:8001
depends_on:
- runtime
- mailer
- postgres
- redis
- nats
mailer:
image: onasty:mailer
container_name: onasty-mailer
build:
context: .
dockerfile: ./mailer/Dockerfile
env_file: ./mailer/.env
depends_on:
- runtime
- nats
seed:
image: onasty:seed
build:
context: .
dockerfile: seed.Dockerfile
entrypoint: ["/seed"]
env_file: .env
profiles: [manual]
depends_on:
- postgres
postgres:
image: postgres:16-alpine
container_name: onasty-postgres
environment:
POSTGRES_USER: onasty
POSTGRES_PASSWORD: qwerty
POSTGRES_DB: onasty
volumes:
- .docker/postgres:/var/lib/postgresql/data
ports:
- 5432:5432
nats:
image: nats:2.10
ports:
- 4222:4222
redis:
image: redis:7.4-alpine
container_name: onasty-redis
ports:
- 6379:6379
prometheus:
image: prom/prometheus
container_name: onasty-prometheus
user: root
volumes:
- ./.docker/prometheus:/prometheus
- ./infra/prometheus:/etc/prometheus
ports:
- 9090:9090
grafana:
image: grafana/grafana:11.1.6
container_name: onasty-grafana
user: root
environment:
- GF_SECURITY_ADMIN_USER=admin
- GF_SECURITY_ADMIN_PASSWORD=admin
volumes:
- ./.docker/grafana:/var/lib/grafana
- ./infra/grafana/datasources.yml:/etc/grafana/provisioning/datasources/datasources.yml
- ./infra/grafana/dashboards.yml:/etc/grafana/provisioning/dashboards/dashboards.yml
- ./infra/grafana/dashboards:/etc/grafana/provisioning/dashboards
ports:
- 3069:3000
loki:
image: grafana/loki:3.2.0
command: ["--pattern-ingester.enabled=true", "-config.file=/etc/loki/config.yaml"]
ports:
- 3100:3100
volumes:
- ./infra/loki/config.yaml:/etc/loki/config.yaml
promtail:
image: grafana/promtail:3.0.0
command: -config.file=/etc/promtail/config.yaml
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./infra/promtail/config.yaml:/etc/promtail/config.yaml
swagger-ui:
image: swaggerapi/swagger-ui
container_name: swagger-ui
ports:
- 8080:8080
volumes:
- ./api/dist/bundle.yml:/usr/share/nginx/html/openapi.yml:ro
environment:
SWAGGER_JSON_URL: openapi.yml
depends_on:
- core
|