feat: add Redis cache, gzip, CI/CD via Gitea self-hosted runner
This commit is contained in:
@@ -18,6 +18,26 @@ services:
|
||||
- ubigeo_network
|
||||
- easypanel
|
||||
|
||||
redis:
|
||||
image: redis:7-alpine
|
||||
container_name: ubigeo-redis
|
||||
restart: unless-stopped
|
||||
command: >
|
||||
redis-server
|
||||
--maxmemory 128mb
|
||||
--maxmemory-policy allkeys-lru
|
||||
--appendonly yes
|
||||
--appendfsync everysec
|
||||
volumes:
|
||||
- redis_data:/data
|
||||
healthcheck:
|
||||
test: ["CMD", "redis-cli", "ping"]
|
||||
interval: 10s
|
||||
timeout: 3s
|
||||
retries: 5
|
||||
networks:
|
||||
- ubigeo_network
|
||||
|
||||
api:
|
||||
image: ubigeo-api:latest
|
||||
container_name: ubigeo-api
|
||||
@@ -26,23 +46,21 @@ services:
|
||||
- "127.0.0.1:3200:3200"
|
||||
environment:
|
||||
DATABASE_URL: "postgresql://ubigeo_user:UbigeoDB2026@postgres:5432/ubigeo_db"
|
||||
REDIS_URL: "redis://ubigeo-redis:6379"
|
||||
PORT: 3200
|
||||
NODE_ENV: production
|
||||
depends_on:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
- "traefik.http.routers.ubigeo.rule=Host(`api-ubigeo.darkcodex.dev`)"
|
||||
- "traefik.http.routers.ubigeo.entrypoints=websecure"
|
||||
- "traefik.http.routers.ubigeo.tls=true"
|
||||
- "traefik.http.services.ubigeo.loadbalancer.server.port=3200"
|
||||
redis:
|
||||
condition: service_healthy
|
||||
networks:
|
||||
- ubigeo_network
|
||||
- easypanel
|
||||
|
||||
volumes:
|
||||
postgres_data:
|
||||
redis_data:
|
||||
|
||||
networks:
|
||||
ubigeo_network:
|
||||
|
||||
Reference in New Issue
Block a user