docker-compose.yml 602 B

12345678910111213141516171819202122232425262728293031
  1. version: '3.8'
  2. services:
  3. postgres:
  4. image: postgres:15-alpine
  5. restart: always
  6. environment:
  7. POSTGRES_USER: postgres
  8. POSTGRES_PASSWORD: postgres
  9. POSTGRES_DB: vtorio
  10. ports:
  11. - "5432:5432"
  12. volumes:
  13. - postgres_data:/var/lib/postgresql/data
  14. app:
  15. build: .
  16. restart: always
  17. ports:
  18. - "3000:3000"
  19. environment:
  20. DATABASE_URL: "postgresql://postgres:postgres@postgres:5432/vtorio?schema=public"
  21. ROOT_PATH: "/app"
  22. depends_on:
  23. - postgres
  24. volumes:
  25. - ./:/app
  26. - /app/node_modules
  27. volumes:
  28. postgres_data: