services: postgres: image: postgres:16-alpine container_name: ticketsystem-db environment: POSTGRES_DB: ticketsystem POSTGRES_USER: postgres POSTGRES_PASSWORD: postgrespassword volumes: - postgres_data:/var/lib/postgresql/data ports: - "5432:5432" networks: - ticketsystem-network restart: unless-stopped backend: build: ./Backend container_name: ticketsystem-backend environment: SPRING_DATASOURCE_URL: jdbc:postgresql://postgres:5432/ticketsystem SPRING_DATASOURCE_USERNAME: postgres SPRING_DATASOURCE_PASSWORD: postgrespassword ports: - "8080:8080" depends_on: - postgres networks: - ticketsystem-network restart: unless-stopped frontend: build: ./Frontend container_name: ticketsystem-frontend environment: NEXT_PUBLIC_API_URL: http://localhost:8080/api API_URL: http://backend:8080 ports: - "3000:3000" depends_on: - backend networks: - ticketsystem-network restart: unless-stopped networks: ticketsystem-network: driver: bridge volumes: postgres_data: