From bb9e1ce024a23c89caae5cf83bafc9b76be6cd9c Mon Sep 17 00:00:00 2001 From: Justin Garrison Date: Sun, 3 Nov 2024 21:23:32 -0800 Subject: [PATCH 1/2] Remove docker compose host networking Add manual port forwarding only for required caddy service Signed-off-by: Justin Garrison --- compose.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/compose.yaml b/compose.yaml index 8cdbfb5..c630ae7 100644 --- a/compose.yaml +++ b/compose.yaml @@ -1,9 +1,11 @@ -version: '3.9' +version: "3.9" services: caddy: container_name: caddy image: caddy:2 - network_mode: host + ports: + - "80:80" + - "443:443" depends_on: - pds restart: unless-stopped @@ -17,7 +19,6 @@ services: pds: container_name: pds image: ghcr.io/bluesky-social/pds:0.4 - network_mode: host restart: unless-stopped volumes: - type: bind @@ -28,7 +29,6 @@ services: watchtower: container_name: watchtower image: containrrr/watchtower:latest - network_mode: host volumes: - type: bind source: /var/run/docker.sock From 512ecb1c3cb8e64a2f36d09810155a0696bb10c7 Mon Sep 17 00:00:00 2001 From: Justin Garrison Date: Sun, 3 Nov 2024 21:52:14 -0800 Subject: [PATCH 2/2] Update installer to not query localhost Signed-off-by: Justin Garrison --- installer.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/installer.sh b/installer.sh index 639039c..a3c39b8 100644 --- a/installer.sh +++ b/installer.sh @@ -309,7 +309,7 @@ DOCKERD_CONFIG { email ${PDS_ADMIN_EMAIL} on_demand_tls { - ask http://localhost:3000/tls-check + ask http://pds:3000/tls-check } } @@ -317,7 +317,7 @@ DOCKERD_CONFIG tls { on_demand } - reverse_proxy http://localhost:3000 + reverse_proxy http://pds:3000 } CADDYFILE