2022-01-31 14:16:31 +02:00
|
|
|
steps:
|
|
|
|
- id: 'docker_amd64'
|
|
|
|
name: 'docker'
|
|
|
|
entrypoint: 'sh'
|
|
|
|
args:
|
|
|
|
- '-c'
|
|
|
|
- |
|
|
|
|
docker build \
|
|
|
|
-t darthsim/imgproxy:$TAG_NAME-amd64 \
|
|
|
|
-f docker/Dockerfile \
|
2022-01-31 15:04:47 +02:00
|
|
|
--platform=linux/amd64 \
|
2022-01-31 14:16:31 +02:00
|
|
|
.
|
|
|
|
env:
|
|
|
|
- DOCKER_BUILDKIT=1
|
|
|
|
waitFor: ["-"]
|
|
|
|
|
|
|
|
- id: 'docker_arm64'
|
|
|
|
name: 'docker'
|
|
|
|
entrypoint: 'sh'
|
|
|
|
args:
|
|
|
|
- '-c'
|
|
|
|
- |
|
2023-11-28 00:21:01 +02:00
|
|
|
docker run --rm --privileged multiarch/qemu-user-static --reset -p yes \
|
2022-01-31 14:16:31 +02:00
|
|
|
&& docker build \
|
|
|
|
-t darthsim/imgproxy:$TAG_NAME-arm64 \
|
|
|
|
-f docker/Dockerfile \
|
2022-01-31 15:04:47 +02:00
|
|
|
--platform=linux/arm64/v8 \
|
2022-01-31 14:16:31 +02:00
|
|
|
.
|
|
|
|
env:
|
|
|
|
- DOCKER_BUILDKIT=1
|
|
|
|
waitFor: ["-"]
|
|
|
|
|
|
|
|
- id: 'push'
|
|
|
|
name: 'docker'
|
|
|
|
entrypoint: 'sh'
|
|
|
|
args:
|
|
|
|
- '-c'
|
|
|
|
- |
|
|
|
|
apk add --no-cache bash \
|
|
|
|
&& docker login -u darthsim -p $$DOCKER_HUB_TOKEN \
|
|
|
|
&& docker/push-images.sh ${TAG_NAME}
|
|
|
|
secretEnv: ['DOCKER_HUB_TOKEN']
|
|
|
|
waitFor: ['docker_amd64', 'docker_arm64']
|
|
|
|
|
|
|
|
|
|
|
|
availableSecrets:
|
|
|
|
secretManager:
|
|
|
|
- versionName: projects/${PROJECT_ID}/secrets/DOCKER_HUB_TOKEN/versions/latest
|
|
|
|
env: DOCKER_HUB_TOKEN
|
|
|
|
|
|
|
|
options:
|
|
|
|
machineType: 'N1_HIGHCPU_8'
|
2022-02-15 14:23:24 +02:00
|
|
|
logging: CLOUD_LOGGING_ONLY
|
2022-01-31 14:16:31 +02:00
|
|
|
dynamic_substitutions: true
|
|
|
|
|
|
|
|
timeout: 1200s
|