bd28b60338
- Uppdatera robust_client.go med rätt tabellnamn (boc_chart_of_accounts, boc_journal_lines, boc_journal_entries) - Uppdatera kolumnnamn (entry_id istället för journal_entry_id, account_code istället för code) - Hantera både stora och små bokstäver för account_type - Lägg till ledgerApi i frontend med BalanceSheet, IncomeStatement, MomsReport - Uppdatera DashboardPage med Ledger KPI-kort - Lägg till LEDGER_DB_URL i docker-compose.yml - Uppdatera Dockerfile till golang:1.25-alpine
82 lines
2.0 KiB
YAML
82 lines
2.0 KiB
YAML
version: '3.8'
|
|
|
|
services:
|
|
postgres:
|
|
image: postgres:16-alpine
|
|
container_name: boc-postgres
|
|
environment:
|
|
POSTGRES_USER: boc
|
|
POSTGRES_PASSWORD: ${DB_PASSWORD:-boc_secret_2026}
|
|
POSTGRES_DB: boc
|
|
volumes:
|
|
- postgres_data:/var/lib/postgresql/data
|
|
- ./backend/db/migrations:/docker-entrypoint-initdb.d:ro
|
|
ports:
|
|
- "5435:5432"
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U boc"]
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 5
|
|
networks:
|
|
- boc-network
|
|
|
|
redis:
|
|
image: redis:7-alpine
|
|
container_name: boc-redis
|
|
command: redis-server --appendonly yes --maxmemory 256mb --maxmemory-policy allkeys-lru
|
|
volumes:
|
|
- redis_data:/data
|
|
ports:
|
|
- "6381:6379"
|
|
healthcheck:
|
|
test: ["CMD", "redis-cli", "ping"]
|
|
interval: 5s
|
|
timeout: 3s
|
|
retries: 5
|
|
networks:
|
|
- boc-network
|
|
|
|
boc-api:
|
|
build:
|
|
context: ./backend
|
|
dockerfile: Dockerfile
|
|
container_name: boc-api
|
|
environment:
|
|
PORT: "9092"
|
|
DB_URL: "postgres://boc:${DB_PASSWORD:-boc_secret_2026}@postgres:5432/boc?sslmode=disable"
|
|
JWT_SECRET: ${JWT_SECRET:?JWT_SECRET must be set}
|
|
AMOS_BASE_URL: "http://172.17.0.1:3250"
|
|
LEDGER_URL: "http://172.17.0.1:3250"
|
|
LEDGER_DB_URL: "postgres://boc:boc_secret_2026@postgres:5432/boc?sslmode=disable"
|
|
MIGRATIONS_DIR: "./db/migrations"
|
|
REDIS_URL: "redis://redis:6379"
|
|
RESEND_API_KEY: ${RESEND_API_KEY:-}
|
|
FROM_EMAIL: ${FROM_EMAIL:-noreply@landvex.com}
|
|
ports:
|
|
- "9096:9092"
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
redis:
|
|
condition: service_healthy
|
|
volumes:
|
|
- ./backend/db/migrations:/app/db/migrations:ro
|
|
- ./backend/auth:/app/auth:ro
|
|
restart: unless-stopped
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "wget -qO- http://localhost:9092/health >/dev/null 2>&1"]
|
|
interval: 10s
|
|
timeout: 5s
|
|
retries: 3
|
|
networks:
|
|
- boc-network
|
|
|
|
volumes:
|
|
postgres_data:
|
|
redis_data:
|
|
|
|
networks:
|
|
boc-network:
|
|
driver: bridge
|