Skip to content

Commit 29bcd0c

Browse files
author
Evans Aboge (from Dev Box)
committed
Fix buildx
1 parent dc0dd67 commit 29bcd0c

File tree

1 file changed

+7
-12
lines changed

1 file changed

+7
-12
lines changed

.azure-pipelines/ci-build.yml

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -427,28 +427,23 @@ extends:
427427
echo "Building Docker image..."
428428
echo "Using build date: ${BUILDDATE}"
429429
# Using quotes around tags to prevent flag interpretation
430-
docker buildx \
431-
--platform linux/arm64/v8 \
430+
docker buildx build \
431+
--platform linux/amd64,linux/arm64/v8,linux/arm/v7 \
432+
--push \
432433
-t "$(REGISTRY)/$(IMAGE_NAME):nightly" \
433434
-t "$(REGISTRY)/$(IMAGE_NAME):${VERSION}.${BUILDDATE}${RUNNUMBER}" \
434435
"$(Build.SourcesDirectory)"
435-
436-
echo "Pushing Docker image with nightly tag..."
437-
docker push "$(REGISTRY)/$(IMAGE_NAME):nightly"
438-
docker push "$(REGISTRY)/$(IMAGE_NAME):${VERSION}.${BUILDDATE}${RUNNUMBER}"
436+
439437
displayName: 'Build and Push Nightly Image'
440438
condition: eq(variables['Build.SourceBranch'], variables['PREVIEW_BRANCH'])
441439
442440
- bash: |
443441
echo "Building Docker image for release..."
444-
docker buildx \
445-
--platform linux/arm64/v8 \
442+
docker buildx build\
443+
--platform linux/amd64,linux/arm64/v8,linux/arm/v7 \
444+
--push \
446445
-t "$(REGISTRY)/$(IMAGE_NAME):latest" \
447446
-t "$(REGISTRY)/$(IMAGE_NAME):${VERSION}.${BUILDDATE}${RUNNUMBER}" \
448447
"$(Build.SourcesDirectory)"
449-
450-
echo "Pushing Docker image with latest and version tags..."
451-
docker push "$(REGISTRY)/$(IMAGE_NAME):latest"
452-
docker push "$(REGISTRY)/$(IMAGE_NAME):${VERSION}.${BUILDDATE}${RUNNUMBER}"
453448
displayName: 'Build and Push Release Image'
454449
condition: contains(variables['Build.SourceBranch'], 'refs/tags/v')

0 commit comments

Comments
 (0)