From 434bfb3fda4e341252986e154e964fdcdf98ce11 Mon Sep 17 00:00:00 2001 From: Divyam Agarwal Date: Tue, 27 Oct 2026 23:46:04 +0530 Subject: [PATCH 1/2] ci(deploy): rebuild urunc-deploy on go.mod/go.sum changes Dependency updates change the urunc binary shipped in the urunc-deploy image, but the build trigger ignored go.mod and go.sum. Add them to the push paths so the image is rebuilt when dependencies change. Signed-off-by: Divyam Agarwal --- .github/workflows/build-trigger.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/build-trigger.yml b/.github/workflows/build-trigger.yml index 38f358151..fbc86f20e 100644 --- a/.github/workflows/build-trigger.yml +++ b/.github/workflows/build-trigger.yml @@ -12,6 +12,8 @@ on: - 'internal/**' - 'Makefile' - 'VERSION' + - 'go.mod' + - 'go.sum' workflow_dispatch: concurrency: From e7bcd65d17a0a5c062743519fc2438d45c0cfd64 Mon Sep 17 00:00:00 2001 From: Divyam Agarwal Date: Tue, 27 Oct 2026 23:46:05 +0530 Subject: [PATCH 2/2] build: add Makefile target for the urunc-deploy image Add a urunc_deploy target that builds the urunc-deploy image from the repository root and passes COMMIT as a build-arg. This avoids local builds that embed an empty commit in the urunc version string. Signed-off-by: Divyam Agarwal --- Makefile | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/Makefile b/Makefile index afe535844..9a8d0b2cb 100644 --- a/Makefile +++ b/Makefile @@ -94,6 +94,10 @@ LINT_CNTR_CMD ?= golangci-lint run -v --timeout=5m #? DOCS_CNTR_IMG The mkdocs image to use (default: harbor.nbfc.io/nubificus/urunc/mkdocs:test) DOCS_CNTR_IMG ?= harbor.nbfc.io/nubificus/urunc/mkdocs:latest +#? URUNC_DEPLOY_IMG Name and tag of the urunc-deploy image (default: urunc-deploy:latest) +URUNC_DEPLOY_IMG ?= urunc-deploy:latest +URUNC_DEPLOY_DOCKERFILE := $(CURDIR)/deployment/urunc-deploy/Dockerfile + # Install dependencies variables # # If we have already built either static or dynamic version of urunc @@ -232,6 +236,19 @@ docs: docs_container: $(CNTR_TOOL) $(CNTR_OPTS) -p 8000:8000 -v $${PWD}:/docs $(DOCS_CNTR_IMG) +# Deployment targets +# +# The urunc-deploy image must be built from the repository root and needs +# COMMIT as a build-arg, otherwise the embedded version has no commit. +## urunc_deploy Build the urunc-deploy container image for host arch. +.PHONY: urunc_deploy +urunc_deploy: + $(CNTR_TOOL) build \ + --build-arg COMMIT=$(COMMIT) \ + -f $(URUNC_DEPLOY_DOCKERFILE) \ + -t $(URUNC_DEPLOY_IMG) \ + $(CURDIR) + # Testing targets ## test Run all tests .PHONY: test