darfdx
darfdx
TTCTheo's Typesafe Cult
Created by darfdx on 1/21/2025 in #questions
[SOLVED] New to Docker, can't connect from localhost to DB on container
Thanks!
21 replies
TTCTheo's Typesafe Cult
Created by darfdx on 1/21/2025 in #questions
[SOLVED] New to Docker, can't connect from localhost to DB on container
Welp, that was it
21 replies
TTCTheo's Typesafe Cult
Created by darfdx on 1/21/2025 in #questions
[SOLVED] New to Docker, can't connect from localhost to DB on container
I had a Postgres server running
21 replies
TTCTheo's Typesafe Cult
Created by darfdx on 1/21/2025 in #questions
[SOLVED] New to Docker, can't connect from localhost to DB on container
bruh
21 replies
TTCTheo's Typesafe Cult
Created by darfdx on 1/21/2025 in #questions
[SOLVED] New to Docker, can't connect from localhost to DB on container
No description
21 replies
TTCTheo's Typesafe Cult
Created by darfdx on 1/21/2025 in #questions
[SOLVED] New to Docker, can't connect from localhost to DB on container
No description
21 replies
TTCTheo's Typesafe Cult
Created by darfdx on 1/21/2025 in #questions
[SOLVED] New to Docker, can't connect from localhost to DB on container
I tried giving privileges to postgres user, but I get the same error
21 replies
TTCTheo's Typesafe Cult
Created by darfdx on 1/21/2025 in #questions
[SOLVED] New to Docker, can't connect from localhost to DB on container
No description
21 replies
TTCTheo's Typesafe Cult
Created by darfdx on 1/21/2025 in #questions
[SOLVED] New to Docker, can't connect from localhost to DB on container
The tutorial also had something about networks on the compose.yml file. I have tried with and without it and get the same result:
services:
db:
image: postgres:17
environment:
- POSTGRES_USER=${DB_USER}
- POSTGRES_PASSWORD=${DB_PASSWORD}
- POSTGRES_DB=${DB_NAME}
volumes:
- pgdata:/var/lib/postgresql/data
networks:
- betternews-network
ports:
- "5432:5432"

networks:
betternews-network:
driver: bridge

volumes:
pgdata:
services:
db:
image: postgres:17
environment:
- POSTGRES_USER=${DB_USER}
- POSTGRES_PASSWORD=${DB_PASSWORD}
- POSTGRES_DB=${DB_NAME}
volumes:
- pgdata:/var/lib/postgresql/data
networks:
- betternews-network
ports:
- "5432:5432"

networks:
betternews-network:
driver: bridge

volumes:
pgdata:
21 replies