From 89106e95afc511d5ae63a6625c30c0e681b4ef31 Mon Sep 17 00:00:00 2001 From: Chever John Date: Wed, 17 Jun 2026 10:28:17 +0800 Subject: [PATCH] fix(ci): use host networking and custom DNS for DinD builds Co-Authored-By: Claude --- .gitlab-ci.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index d6923c9..95faa3e 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -13,7 +13,8 @@ build-frontend: stage: build image: docker:27 services: - - docker:27-dind + - name: docker:27-dind + command: ["--dns", "10.43.0.10", "--dns", "223.5.5.5"] retry: 2 before_script: - until docker info >/dev/null 2>&1; do echo "Waiting for Docker daemon..."; sleep 2; done @@ -25,7 +26,7 @@ build-frontend: else TAG="main-${CI_COMMIT_SHORT_SHA}" fi - - docker build -t $HARBOR_REGISTRY/$HARBOR_PROJECT/iloom-frontend:$TAG . + - docker build --network host -t $HARBOR_REGISTRY/$HARBOR_PROJECT/iloom-frontend:$TAG . - docker push $HARBOR_REGISTRY/$HARBOR_PROJECT/iloom-frontend:$TAG rules: - if: $CI_COMMIT_BRANCH == "main"