From d762a2b76f2d8b6c35ed57d41f734c9f0cec9606 Mon Sep 17 00:00:00 2001 From: Celes Renata Date: Mon, 13 Jul 2026 04:47:37 +0000 Subject: [PATCH] fix: use RUN --network=host for npm ci in BuildKit BuildKit sandbox DNS cannot resolve registry.npmjs.org. Using --network=host on the RUN step lets npm use the host network stack directly, bypassing the broken sandbox DNS. --- .woodpecker/build-3.yml | 2 +- frontend/Dockerfile | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.woodpecker/build-3.yml b/.woodpecker/build-3.yml index 97ac047..84b8333 100644 --- a/.woodpecker/build-3.yml +++ b/.woodpecker/build-3.yml @@ -197,7 +197,7 @@ steps: registry: registry.celestium.life buildx_image: registry.celestium.life/dockerhub-cache/moby/buildkit:buildx-stable-1 add_host: registry.celestium.life:10.1.1.12 - buildx_flags: --driver-opt network=host + buildx_flags: --driver-opt network=host --allow network.host insecure: true buildkit_config: | [registry."registry.celestium.life"] diff --git a/frontend/Dockerfile b/frontend/Dockerfile index e26ec47..8244e59 100644 --- a/frontend/Dockerfile +++ b/frontend/Dockerfile @@ -1,9 +1,10 @@ +# syntax=docker/dockerfile:1 # Stage 1: Build # Base images: uses Harbor proxy cache in CI, falls back to Docker Hub externally FROM registry.celestium.life/dockerhub-cache/library/node:24-alpine AS build WORKDIR /app COPY package.json package-lock.json ./ -RUN echo "nameserver 8.8.8.8" > /etc/resolv.conf && echo "nameserver 1.1.1.1" >> /etc/resolv.conf && npm ci +RUN --network=host npm ci COPY . . ARG VITE_QUERY_API_URL="" ARG VITE_SYMBOL_REGISTRY_URL=""