diff --git a/.drone.jsonnet b/.drone.jsonnet index ba678d6..abc17b4 100644 --- a/.drone.jsonnet +++ b/.drone.jsonnet @@ -39,18 +39,18 @@ local PipelineBuildContainer(arch='amd64') = { }, { name: 'dryrun', - image: 'jdrouet/docker-with-buildx:stable', - commands: [ - 'docker buildx create --use', - 'docker buildx build --platform linux/' + std.strReplace(arch, '_', '/') + ' --tag thegeeklab/buildx-alpine:latest -f "$$DOCKERFILE" .', - ], - environment: { - DOCKERFILE: 'Dockerfile.' + std.split(arch, '_')[0], + image: 'thegeeklab/drone-docker-buildx', + settings: { + config: { from_secret: 'docker_config' }, + dry_run: true, + dockerfile: 'docker/Dockerfile.' + std.split(arch, '_')[0], + platforms: [ + 'linux/' + std.strReplace(arch, '_', '/'), + ], + repo: 'thegeeklab/buildx-alpine', + username: { from_secret: 'docker_username' }, + password: { from_secret: 'docker_password' }, }, - volumes: [{ - name: 'dockersock-' + arch, - path: '/var/run', - }], depends_on: ['wait-for'], when: { ref: ['refs/pull/**'], diff --git a/.drone.yml b/.drone.yml index 512c096..967867f 100644 --- a/.drone.yml +++ b/.drone.yml @@ -35,15 +35,19 @@ steps: WAITFOR_TIMEOUT: 60 - name: dryrun - image: jdrouet/docker-with-buildx:stable - commands: - - docker buildx create --use - - docker buildx build --platform linux/amd64 --tag thegeeklab/buildx-alpine:latest -f "$$DOCKERFILE" . - environment: - DOCKERFILE: Dockerfile.amd64 - volumes: - - name: dockersock-amd64 - path: /var/run + image: thegeeklab/drone-docker-buildx + settings: + config: + from_secret: docker_config + dockerfile: docker/Dockerfile.amd64 + dry_run: true + password: + from_secret: docker_password + platforms: + - linux/amd64 + repo: thegeeklab/buildx-alpine + username: + from_secret: docker_username when: ref: - refs/pull/** @@ -124,15 +128,19 @@ steps: WAITFOR_TIMEOUT: 60 - name: dryrun - image: jdrouet/docker-with-buildx:stable - commands: - - docker buildx create --use - - docker buildx build --platform linux/arm64/v8 --tag thegeeklab/buildx-alpine:latest -f "$$DOCKERFILE" . - environment: - DOCKERFILE: Dockerfile.arm64 - volumes: - - name: dockersock-arm64_v8 - path: /var/run + image: thegeeklab/drone-docker-buildx + settings: + config: + from_secret: docker_config + dockerfile: docker/Dockerfile.arm64 + dry_run: true + password: + from_secret: docker_password + platforms: + - linux/arm64/v8 + repo: thegeeklab/buildx-alpine + username: + from_secret: docker_username when: ref: - refs/pull/** @@ -213,15 +221,19 @@ steps: WAITFOR_TIMEOUT: 60 - name: dryrun - image: jdrouet/docker-with-buildx:stable - commands: - - docker buildx create --use - - docker buildx build --platform linux/arm/v7 --tag thegeeklab/buildx-alpine:latest -f "$$DOCKERFILE" . - environment: - DOCKERFILE: Dockerfile.arm - volumes: - - name: dockersock-arm_v7 - path: /var/run + image: thegeeklab/drone-docker-buildx + settings: + config: + from_secret: docker_config + dockerfile: docker/Dockerfile.arm + dry_run: true + password: + from_secret: docker_password + platforms: + - linux/arm/v7 + repo: thegeeklab/buildx-alpine + username: + from_secret: docker_username when: ref: - refs/pull/** @@ -358,6 +370,6 @@ depends_on: --- kind: signature -hmac: 1529e330f44c46887ec7fb431cf29ee6e65dde07f81f1206166d0de540a06e67 +hmac: 0d15eda6b01d23551b72f8e12348bb1028d19c0b30cf28be2f38e737a3f9a51d ...