From 5531a42ed774e92fbe8e81ef80b2d7428817a1e4 Mon Sep 17 00:00:00 2001 From: ruberoid Date: Tue, 28 Oct 2025 00:04:59 +0400 Subject: [PATCH] fix: Add --build-context=rootconfig flag to Kaniko builds The recent docker-compose.yml change added additional_contexts with 'rootconfig' reference. Dockerfiles now use 'COPY --from=rootconfig nuget.config' which works with Docker Compose but breaks Kaniko builds. Added --build-context=rootconfig=. flag to all Kaniko executor commands to provide the named build context that Dockerfiles expect. This matches Docker Compose behavior and fixes the 'rootconfig' image pull error. --- .drone.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.drone.yml b/.drone.yml index c579832..d6c5ddb 100644 --- a/.drone.yml +++ b/.drone.yml @@ -439,6 +439,7 @@ steps: - | /kaniko/executor \ --context=. \ + --build-context=rootconfig=. \ --dockerfile=src/Nocr.TelegramListener.Host/Dockerfile \ --destination=hub.musk.fun/k8s/nocr/telegram_listener:${DRONE_COMMIT_SHA:0:7} \ --destination=hub.musk.fun/k8s/nocr/telegram_listener:${DRONE_TAG} \ @@ -465,6 +466,7 @@ steps: - | /kaniko/executor \ --context=. \ + --build-context=rootconfig=. \ --dockerfile=src/Nocr.TelegramClient.Host/Dockerfile \ --destination=hub.musk.fun/k8s/nocr/telegram_client:${DRONE_COMMIT_SHA:0:7} \ --destination=hub.musk.fun/k8s/nocr/telegram_client:${DRONE_TAG} \ @@ -491,6 +493,7 @@ steps: - | /kaniko/executor \ --context=. \ + --build-context=rootconfig=. \ --dockerfile=src/Nocr.TextMatcher.Host/Dockerfile \ --destination=hub.musk.fun/k8s/nocr/text_matcher:${DRONE_COMMIT_SHA:0:7} \ --destination=hub.musk.fun/k8s/nocr/text_matcher:${DRONE_TAG} \ @@ -517,6 +520,7 @@ steps: - | /kaniko/executor \ --context=. \ + --build-context=rootconfig=. \ --dockerfile=src/Nocr.TextMatcher.Migrator/Dockerfile \ --destination=hub.musk.fun/k8s/nocr/text_matcher_migrator:${DRONE_COMMIT_SHA:0:7} \ --destination=hub.musk.fun/k8s/nocr/text_matcher_migrator:${DRONE_TAG} \ @@ -543,6 +547,7 @@ steps: - | /kaniko/executor \ --context=. \ + --build-context=rootconfig=. \ --dockerfile=src/Nocr.Users.Host/Dockerfile \ --destination=hub.musk.fun/k8s/nocr/users:${DRONE_COMMIT_SHA:0:7} \ --destination=hub.musk.fun/k8s/nocr/users:${DRONE_TAG} \ @@ -569,6 +574,7 @@ steps: - | /kaniko/executor \ --context=. \ + --build-context=rootconfig=. \ --dockerfile=src/Nocr.Users.Migrator/Dockerfile \ --destination=hub.musk.fun/k8s/nocr/users_migrator:${DRONE_COMMIT_SHA:0:7} \ --destination=hub.musk.fun/k8s/nocr/users_migrator:${DRONE_TAG} \