Added dockerfile, docker compose, created server implementation with some middlewares
This commit is contained in:
98
podman-compose.yml
Normal file
98
podman-compose.yml
Normal file
@@ -0,0 +1,98 @@
|
||||
networks:
|
||||
default:
|
||||
name: LogiflowNetwork
|
||||
external: true
|
||||
|
||||
services:
|
||||
postgres:
|
||||
networks:
|
||||
- default
|
||||
image: docker.io/library/postgres:latest
|
||||
restart: always
|
||||
container_name: logiflow-postgres
|
||||
env_file:
|
||||
- .env
|
||||
ports:
|
||||
- "5432:5432"
|
||||
volumes:
|
||||
- postgres_data:/var/lib/postgresql
|
||||
- ./migrations:/docker-entrypoint-initdb.d
|
||||
environment:
|
||||
POSTGRES_PASSWORD: ${LOGIFLOW_DATABASE_PASSWORD}
|
||||
POSTGRES_USER: ${LOGIFLOW_DATABASE_USER}
|
||||
POSTGRES_DB: ${LOGIFLOW_DATABASE_NAME}
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U ${LOGIFLOW_DATABASE_USER}"]
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
redis:
|
||||
networks:
|
||||
- default
|
||||
image: docker.io/library/redis:7-alpine
|
||||
container_name: logiflow-redis
|
||||
ports:
|
||||
- "6379:6379"
|
||||
volumes:
|
||||
- redis_data:/data
|
||||
command: redis-server --requirepass ${LOGIFLOW_REDIS_PASSWORD}
|
||||
env_file:
|
||||
- .env
|
||||
healthcheck:
|
||||
test: ["CMD", "redis-cli", "-a", "${LOGIFLOW_REDIS_PASSWORD}", "ping"]
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
prometheus:
|
||||
networks:
|
||||
- default
|
||||
image: docker.io/prom/prometheus:latest
|
||||
container_name: logiflow-prometheus
|
||||
ports:
|
||||
- "9090:9090"
|
||||
volumes:
|
||||
- ./configs/prometheus.yml:/etc/prometheus/prometheus.yml:ro
|
||||
command:
|
||||
- "--config.file=/etc/prometheus/prometheus.yml"
|
||||
|
||||
grafana:
|
||||
networks:
|
||||
- default
|
||||
image: docker.io/grafana/grafana:latest
|
||||
container_name: logiflow-grafana
|
||||
ports:
|
||||
- "3000:3000"
|
||||
env_file:
|
||||
- .env
|
||||
environment:
|
||||
GF_SECURITY_ADMIN_USER: admin
|
||||
GF_SECURITY_ADMIN_PASSWORD: admin
|
||||
volumes:
|
||||
- grafana_data:/var/lib/grafana
|
||||
- ./configs/datasources:/etc/grafana/provisioning/datasources:ro
|
||||
depends_on:
|
||||
- prometheus
|
||||
|
||||
app:
|
||||
networks:
|
||||
- default
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
container_name: logiflow-app
|
||||
ports:
|
||||
- "3001:3001"
|
||||
env_file:
|
||||
- .env
|
||||
depends_on:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
redis:
|
||||
condition: service_healthy
|
||||
|
||||
volumes:
|
||||
postgres_data:
|
||||
redis_data:
|
||||
grafana_data:
|
||||
Reference in New Issue
Block a user