Closed metalshanked closed 1 week ago
To resolve the issue where the PostgreSQL container is listening on port 5430:5432
, causing the default settings to fail, you need to update the port mapping in your docker-compose.yml
file to use the default PostgreSQL port 5432:5432
.
Here is the updated docker-compose.yml
configuration:
services:
postgresql:
image: postgres:14.2-alpine
environment:
POSTGRES_USER: pandasai
POSTGRES_PASSWORD: password123
POSTGRES_DB: pandasai-db
ports:
- "5432:5432"
volumes:
- ./pgdata:/var/lib/postgresql/data
networks:
- pandabi-network
server:
container_name: pandabi-backend
build:
context: ./server
dockerfile: Dockerfile
ports:
- "8000:8000"
restart: always
env_file:
- ./server/.env
depends_on:
- postgresql
networks:
- pandabi-network
command: "/bin/bash startup.sh"
client:
container_name: pandabi-frontend
build:
context: ./client
dockerfile: Dockerfile
ports:
- "3000:3000"
restart: always
env_file:
- ./client/.env
environment:
- NODE_ENV=development
command: npm run start
networks:
- pandabi-network
networks:
pandabi-network:
driver: bridge
By changing the port mapping from 5430:5432
to 5432:5432
, the PostgreSQL container will listen on the default port 5432
, which should resolve the issue with the default settings [1].
To continue talking to Dosu, mention @dosu.
System Info
pandas 2.2
🐛 Describe the bug
get the below error when following the steps to run the platform with docker compose as mentioned in the docs.
I think the postgres container is listening on 5430:5432 so the default settings fail as below.
pandabi-backend | raise OSError(err, f'Connect call failed {address}') pandabi-backend | ConnectionRefusedError: [Errno 111] Connect call failed ('127.0.0.1', 5432)