From fce6b346796599819d2a12d7864f48010a143e48 Mon Sep 17 00:00:00 2001 From: Daniel Togey Date: Sat, 24 Jan 2026 17:46:14 +0300 Subject: [PATCH 1/2] fix: include static assets in web container and improve IP detection --- deploy/Containerfile.web | 11 +++++++++-- scripts/install.sh | 7 ++++++- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/deploy/Containerfile.web b/deploy/Containerfile.web index 120ae53..14b61b8 100644 --- a/deploy/Containerfile.web +++ b/deploy/Containerfile.web @@ -44,10 +44,17 @@ FROM docker.io/library/alpine:3.20 RUN apk add --no-cache ca-certificates curl -COPY --from=builder /web /usr/local/bin/web +# Create app directory structure +WORKDIR /app + +# Copy binary +COPY --from=builder /web /app/web + +# Copy static assets (CSS, JS) +COPY --from=builder /build/web/assets /app/web/assets EXPOSE 8090 USER nobody:nobody -ENTRYPOINT ["/usr/local/bin/web"] +ENTRYPOINT ["/app/web"] diff --git a/scripts/install.sh b/scripts/install.sh index d1511bf..f8ea045 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -168,7 +168,12 @@ wait_for_healthy() { # ----------------------------------------------------------------------------- print_success() { - PUBLIC_IP=$(curl -sf --max-time 5 https://ifconfig.me 2>/dev/null || echo "localhost") + # Try multiple services to get public IP + PUBLIC_IP=$(curl -sf --max-time 3 https://ifconfig.me 2>/dev/null || \ + curl -sf --max-time 3 https://api.ipify.org 2>/dev/null || \ + curl -sf --max-time 3 https://icanhazip.com 2>/dev/null || \ + hostname -I 2>/dev/null | awk '{print $1}' || \ + echo "YOUR_SERVER_IP") echo "" echo -e "${GREEN}${BOLD}╔════════════════════════════════════════════════════════════════╗${NC}" From 08b7b4dc263c7d6b0d5e2e8f40d3318d62b3ec91 Mon Sep 17 00:00:00 2001 From: Daniel Togey Date: Sat, 24 Jan 2026 17:51:48 +0300 Subject: [PATCH 2/2] fix: correct container paths for binary and assets --- deploy/Containerfile.web | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/deploy/Containerfile.web b/deploy/Containerfile.web index 14b61b8..f7681bc 100644 --- a/deploy/Containerfile.web +++ b/deploy/Containerfile.web @@ -37,24 +37,24 @@ RUN cd web && /usr/local/bin/tailwindcss -i ./assets/css/input.css -o ./assets/c RUN CGO_ENABLED=0 GOOS=linux go build \ -ldflags="-s -w -X main.Version=${VERSION}" \ - -o /web ./cmd/web + -o /narvana-web ./cmd/web # Runtime - Alpine is fine here since we're running a static Go binary FROM docker.io/library/alpine:3.20 RUN apk add --no-cache ca-certificates curl -# Create app directory structure +# Create app directory WORKDIR /app # Copy binary -COPY --from=builder /web /app/web +COPY --from=builder /narvana-web /app/narvana-web -# Copy static assets (CSS, JS) +# Copy static assets (CSS, JS) - must match the path the binary expects: "web/assets" COPY --from=builder /build/web/assets /app/web/assets EXPOSE 8090 USER nobody:nobody -ENTRYPOINT ["/app/web"] +ENTRYPOINT ["/app/narvana-web"]