fix(ci): fix make image DEV_IMAGE=true on non-amd64 architecture (#25897) (#25898)

Signed-off-by: Eugene Doudine <eugene.doudine@octopus.com>
Signed-off-by: dudinea <eugene.doudine@octopus.com>
Co-authored-by: Nitish Kumar <justnitish06@gmail.com>
This commit is contained in:
dudinea
2026-01-11 09:47:03 +02:00
committed by GitHub
parent e6825529ab
commit 946a3ab44b
2 changed files with 13 additions and 1 deletions

View File

@@ -349,7 +349,7 @@ ifeq ($(DEV_IMAGE), true)
IMAGE_TAG="dev-$(shell git describe --always --dirty)"
image: build-ui
DOCKER_BUILDKIT=1 $(DOCKER) build --platform=$(TARGET_ARCH) -t argocd-base --target argocd-base .
CGO_ENABLED=${CGO_FLAG} GOOS=linux GOARCH=amd64 GODEBUG="tarinsecurepath=0,zipinsecurepath=0" go build -v -ldflags '${LDFLAGS}' -o ${DIST_DIR}/argocd ./cmd
GOOS=linux GOARCH=$(TARGET_ARCH:linux/%=%) GODEBUG="tarinsecurepath=0,zipinsecurepath=0" go build -v -ldflags '${LDFLAGS}' -o ${DIST_DIR}/argocd ./cmd
ln -sfn ${DIST_DIR}/argocd ${DIST_DIR}/argocd-server
ln -sfn ${DIST_DIR}/argocd ${DIST_DIR}/argocd-application-controller
ln -sfn ${DIST_DIR}/argocd ${DIST_DIR}/argocd-repo-server

View File

@@ -222,6 +222,18 @@ Then you can build & push the image in one step:
DOCKER_PUSH=true make image
```
To speed up building of images you may use the DEV_IMAGE option that builds the argocd binaries in the users desktop environment
(instead of building everything in Docker) and copies them into the result image:
```bash
DEV_IMAGE=true DOCKER_PUSH=true make image
```
> [!NOTE]
> The first run of this build task may take a long time because it needs first to build the base image first; however,
> once it's done, the build process should be much faster than a regular full image build in Docker.
#### Configure manifests for your image
With `IMAGE_REGISTRY`, `IMAGE_NAMESPACE` and `IMAGE_TAG` still set, run: