feat: ajusta limitis

This commit is contained in:
Jose Eduardo 2025-08-17 22:32:13 -04:00
parent 1f0847569d
commit 53c5d2ac5b

View File

@ -1,6 +1,6 @@
services: services:
api1: api1:
image: payment2:latest image: jos3duardo/rinha-backend-2025:v1.0
restart: always restart: always
networks: networks:
- backend - backend
@ -11,11 +11,11 @@ services:
deploy: deploy:
resources: resources:
limits: limits:
cpus: '0.3' cpus: "0.3"
memory: '64MB' memory: "67MB"
api2: api2:
image: payment2:latest image: jos3duardo/rinha-backend-2025:v1.0
restart: always restart: always
depends_on: depends_on:
- redis - redis
@ -26,11 +26,11 @@ services:
deploy: deploy:
resources: resources:
limits: limits:
cpus: '0.3' cpus: "0.3"
memory: '64MB' memory: "67MB"
api3: api3:
image: payment2:latest image: jos3duardo/rinha-backend-2025:v1.0
restart: always restart: always
depends_on: depends_on:
- redis - redis
@ -41,14 +41,14 @@ services:
deploy: deploy:
resources: resources:
limits: limits:
cpus: '0.3' cpus: "0.3"
memory: '64MB' memory: "67MB"
nginx: nginx:
image: nginx:latest image: nginx:latest
restart: always restart: always
ports: ports:
- '9999:9999' - "9999:9999"
volumes: volumes:
- ./nginx.conf:/etc/nginx/nginx.conf - ./nginx.conf:/etc/nginx/nginx.conf
networks: networks:
@ -60,22 +60,22 @@ services:
deploy: deploy:
resources: resources:
limits: limits:
cpus: '0.15' cpus: "0.10"
memory: '9MB' memory: "9MB"
redis: redis:
image: redis:7.2-alpine image: redis:7.2-alpine
restart: always restart: always
platform: linux/amd64 platform: linux/amd64
ports: ports:
- '6379:6379' - "6379:6379"
networks: networks:
- backend - backend
deploy: deploy:
resources: resources:
limits: limits:
cpus: '0.40' cpus: "0.30"
memory: '25MB' memory: "15MB"
database: database:
image: postgres:17-alpine image: postgres:17-alpine
@ -83,15 +83,15 @@ services:
command: postgres -c checkpoint_timeout=600 -c max_wal_size=4096 -c synchronous_commit=0 -c fsync=0 -c full_page_writes=0 command: postgres -c checkpoint_timeout=600 -c max_wal_size=4096 -c synchronous_commit=0 -c fsync=0 -c full_page_writes=0
platform: linux/amd64 platform: linux/amd64
ports: ports:
- '5432:5432' - "5432:5432"
environment: environment:
- POSTGRES_DB=payment - POSTGRES_DB=payment
- POSTGRES_USER=postgres - POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres_pwd - POSTGRES_PASSWORD=postgres_pwd
volumes: volumes:
- ./init.sql:/docker-entrypoint-initdb.d/init.sql - ./sql/init.sql:/docker-entrypoint-initdb.d/init.sql
healthcheck: healthcheck:
test: ['CMD-SHELL', 'pg_isready -U postgres'] test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 3s interval: 3s
timeout: 3s timeout: 3s
retries: 5 retries: 5
@ -100,8 +100,8 @@ services:
deploy: deploy:
resources: resources:
limits: limits:
cpus: '0.25' cpus: "0.20"
memory: '124MB' memory: "125MB"
networks: networks:
backend: backend: