Skip to content

Commit e08e5e9

Browse files
committed
fix(hosting): bind Postgres and the Traefik dashboard to loopback by default
A self-hoster on a public IP no longer exposes their database (default creds username/password) or an unauthenticated dashboard to the internet. Set POSTGRES_PORT=0.0.0.0:5432 to opt back in. Claude-Session: https://claude.ai/code/session_01XhENr63WL9npkKrJGnzDc1
1 parent 5605cc2 commit e08e5e9

7 files changed

Lines changed: 14 additions & 14 deletions

hosting/docker-compose/ee/docker-compose.dev.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -464,7 +464,7 @@ services:
464464
networks:
465465
- agenta-network
466466
ports:
467-
- "${POSTGRES_PORT:-5432}:5432"
467+
- "${POSTGRES_PORT:-127.0.0.1:5432}:5432"
468468
# === LIFECYCLE ============================================ #
469469
restart: always
470470
healthcheck:
@@ -651,7 +651,7 @@ services:
651651
- agenta-network
652652
ports:
653653
- "${TRAEFIK_PORT:-80}:80"
654-
- "${TRAEFIK_UI_PORT:-8080}:8080"
654+
- "127.0.0.1:${TRAEFIK_UI_PORT:-8080}:8080"
655655
# === LIFECYCLE ============================================ #
656656
restart: always
657657
healthcheck:

hosting/docker-compose/ee/docker-compose.gh.local.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ services:
325325
networks:
326326
- agenta-ee-gh-network
327327
ports:
328-
- "${POSTGRES_PORT:-5432}:5432"
328+
- "${POSTGRES_PORT:-127.0.0.1:5432}:5432"
329329
# === LIFECYCLE ============================================ #
330330
restart: always
331331
healthcheck:
@@ -415,7 +415,7 @@ services:
415415
- agenta-ee-gh-network
416416
ports:
417417
- "${TRAEFIK_PORT:-80}:80"
418-
- "${TRAEFIK_UI_PORT:-8080}:8080"
418+
- "127.0.0.1:${TRAEFIK_UI_PORT:-8080}:8080"
419419
# === LIFECYCLE ============================================ #
420420
restart: always
421421

hosting/docker-compose/ee/docker-compose.gh.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,7 @@ services:
323323
networks:
324324
- agenta-ee-gh-network
325325
ports:
326-
- "${POSTGRES_PORT:-5432}:5432"
326+
- "${POSTGRES_PORT:-127.0.0.1:5432}:5432"
327327
# === LIFECYCLE ============================================ #
328328
restart: always
329329
healthcheck:
@@ -412,7 +412,7 @@ services:
412412
- agenta-ee-gh-network
413413
ports:
414414
- "${TRAEFIK_PORT:-80}:80"
415-
- "${TRAEFIK_UI_PORT:-8080}:8080"
415+
- "127.0.0.1:${TRAEFIK_UI_PORT:-8080}:8080"
416416
# === LIFECYCLE ============================================ #
417417
restart: always
418418

hosting/docker-compose/oss/docker-compose.dev.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -445,7 +445,7 @@ services:
445445
networks:
446446
- agenta-network
447447
ports:
448-
- "${POSTGRES_PORT:-5432}:5432"
448+
- "${POSTGRES_PORT:-127.0.0.1:5432}:5432"
449449
# === LIFECYCLE ============================================ #
450450
restart: always
451451
healthcheck:
@@ -628,7 +628,7 @@ services:
628628
- agenta-network
629629
ports:
630630
- "${TRAEFIK_PORT:-80}:80"
631-
- "${TRAEFIK_UI_PORT:-8080}:8080"
631+
- "127.0.0.1:${TRAEFIK_UI_PORT:-8080}:8080"
632632
# === LIFECYCLE ============================================ #
633633
restart: always
634634
healthcheck:

hosting/docker-compose/oss/docker-compose.gh.local.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,7 @@ services:
323323
networks:
324324
- agenta-oss-gh-network
325325
ports:
326-
- "${POSTGRES_PORT:-5432}:5432"
326+
- "${POSTGRES_PORT:-127.0.0.1:5432}:5432"
327327
# === LIFECYCLE ============================================ #
328328
restart: always
329329
healthcheck:
@@ -415,7 +415,7 @@ services:
415415
- agenta-oss-gh-network
416416
ports:
417417
- "${TRAEFIK_PORT:-80}:80"
418-
- "${TRAEFIK_UI_PORT:-8080}:8080"
418+
- "127.0.0.1:${TRAEFIK_UI_PORT:-8080}:8080"
419419
# === LIFECYCLE ============================================ #
420420
restart: always
421421

hosting/docker-compose/oss/docker-compose.gh.ssl.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,7 @@ services:
347347
networks:
348348
- agenta-gh-ssl-network
349349
ports:
350-
- "${POSTGRES_PORT:-5432}:5432"
350+
- "${POSTGRES_PORT:-127.0.0.1:5432}:5432"
351351
# === LIFECYCLE ============================================ #
352352
restart: always
353353
healthcheck:
@@ -429,7 +429,7 @@ services:
429429
- agenta-gh-ssl-network
430430
ports:
431431
- "${TRAEFIK_PORT:-80}:80"
432-
- "${TRAEFIK_UI_PORT:-8080}:8080"
432+
- "127.0.0.1:${TRAEFIK_UI_PORT:-8080}:8080"
433433
- "${TRAEFIK_HTTPS_PORT:-443}:443"
434434
# === LIFECYCLE ============================================ #
435435
restart: always

hosting/docker-compose/oss/docker-compose.gh.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ services:
340340
networks:
341341
- agenta-oss-gh-network
342342
ports:
343-
- "${POSTGRES_PORT:-5432}:5432"
343+
- "${POSTGRES_PORT:-127.0.0.1:5432}:5432"
344344
# === LIFECYCLE ============================================ #
345345
restart: always
346346
healthcheck:
@@ -432,7 +432,7 @@ services:
432432
- agenta-oss-gh-network
433433
ports:
434434
- "${TRAEFIK_PORT:-80}:80"
435-
- "${TRAEFIK_UI_PORT:-8080}:8080"
435+
- "127.0.0.1:${TRAEFIK_UI_PORT:-8080}:8080"
436436
# === LIFECYCLE ============================================ #
437437
restart: always
438438

0 commit comments

Comments
 (0)