forked from Ivasoft/drone-docker
Compare commits
1 Commits
v19.03.9
...
update-win
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1b71fe6cdd |
486
.drone.yml
486
.drone.yml
@@ -8,7 +8,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: vet
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- go vet ./...
|
||||
environment:
|
||||
@@ -18,7 +19,8 @@ steps:
|
||||
path: /go
|
||||
|
||||
- name: test
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- go test -cover ./...
|
||||
environment:
|
||||
@@ -75,43 +77,43 @@ trigger:
|
||||
depends_on:
|
||||
- testing
|
||||
|
||||
# ---
|
||||
# kind: pipeline
|
||||
# type: ssh
|
||||
# name: windows-1903-amd64-docker
|
||||
---
|
||||
kind: pipeline
|
||||
type: ssh
|
||||
name: windows-1903-amd64-docker
|
||||
|
||||
# platform:
|
||||
# os: windows
|
||||
platform:
|
||||
os: windows
|
||||
|
||||
# server:
|
||||
# host: windows.1903.amd64.plugins.drone.ci
|
||||
# password:
|
||||
# from_secret: windows_password
|
||||
# user:
|
||||
# from_secret: windows_username
|
||||
server:
|
||||
host: windows.1903.amd64.plugins.drone.ci
|
||||
password:
|
||||
from_secret: windows_password
|
||||
user:
|
||||
from_secret: windows_username
|
||||
|
||||
# steps:
|
||||
# - name: build
|
||||
# commands:
|
||||
# # TODO use the new DRONE_SEMVER_SHORT environment variables to
|
||||
# # publish docker images for tag events.
|
||||
# - go build -o release/windows/amd64/drone-docker.exe ./cmd/drone-docker
|
||||
# - docker login -u $env:USERNAME -p $env:PASSWORD
|
||||
# - docker build -f docker/docker/Dockerfile.windows.1903 -t plugins/docker:windows-1903-amd64 .
|
||||
# - docker push plugins/docker:windows-1903-amd64
|
||||
# environment:
|
||||
# CGO_ENABLED: "0"
|
||||
# USERNAME:
|
||||
# from_secret: docker_username
|
||||
# PASSWORD:
|
||||
# from_secret: docker_password
|
||||
steps:
|
||||
- name: build
|
||||
commands:
|
||||
# TODO use the new DRONE_SEMVER_SHORT environment variables to
|
||||
# publish docker images for tag events.
|
||||
- go build -o release/windows/amd64/drone-docker.exe ./cmd/drone-docker
|
||||
- docker login -u $env:USERNAME -p $env:PASSWORD
|
||||
- docker build -f docker/docker/Dockerfile.windows.1903 -t plugins/docker:windows-1903-amd64 .
|
||||
- docker push plugins/docker:windows-1903-amd64
|
||||
environment:
|
||||
CGO_ENABLED: "0"
|
||||
USERNAME:
|
||||
from_secret: docker_username
|
||||
PASSWORD:
|
||||
from_secret: docker_password
|
||||
|
||||
# trigger:
|
||||
# event:
|
||||
# - push
|
||||
trigger:
|
||||
event:
|
||||
- push
|
||||
|
||||
# depends_on:
|
||||
# - testing
|
||||
depends_on:
|
||||
- testing
|
||||
|
||||
---
|
||||
kind: pipeline
|
||||
@@ -161,7 +163,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/amd64/drone-docker ./cmd/drone-docker"
|
||||
environment:
|
||||
@@ -173,7 +176,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/amd64/drone-docker ./cmd/drone-docker"
|
||||
environment:
|
||||
@@ -184,11 +188,30 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: executable
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- ./release/linux/amd64/drone-docker --help
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/docker/Dockerfile.linux.amd64
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/docker
|
||||
tags: linux-amd64
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -224,7 +247,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/arm64/drone-docker ./cmd/drone-docker"
|
||||
environment:
|
||||
@@ -236,7 +260,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/arm64/drone-docker ./cmd/drone-docker"
|
||||
environment:
|
||||
@@ -247,11 +272,30 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: executable
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- ./release/linux/arm64/drone-docker --help
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/docker/Dockerfile.linux.arm64
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/docker
|
||||
tags: linux-arm64
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -287,7 +331,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/arm/drone-docker ./cmd/drone-docker"
|
||||
environment:
|
||||
@@ -299,7 +344,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/arm/drone-docker ./cmd/drone-docker"
|
||||
environment:
|
||||
@@ -310,11 +356,30 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: executable
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- ./release/linux/arm/drone-docker --help
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/docker/Dockerfile.linux.arm
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/docker
|
||||
tags: linux-arm
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -350,6 +415,7 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: manifest
|
||||
pull: always
|
||||
image: plugins/manifest
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -360,6 +426,14 @@ steps:
|
||||
username:
|
||||
from_secret: docker_username
|
||||
|
||||
- name: microbadger
|
||||
pull: always
|
||||
image: plugins/webhook
|
||||
failure: ignore
|
||||
settings:
|
||||
urls:
|
||||
from_secret: microbadger_docker
|
||||
|
||||
trigger:
|
||||
ref:
|
||||
- refs/heads/master
|
||||
@@ -367,11 +441,11 @@ trigger:
|
||||
|
||||
depends_on:
|
||||
- windows-1809-amd64-docker
|
||||
- windows-1903-amd64-docker
|
||||
- windows-1909-amd64-docker
|
||||
- linux-amd64-docker
|
||||
- linux-arm64-docker
|
||||
- linux-arm-docker
|
||||
# - windows-1903-amd64-dfocker
|
||||
|
||||
---
|
||||
kind: pipeline
|
||||
@@ -383,7 +457,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/amd64/drone-gcr ./cmd/drone-gcr"
|
||||
environment:
|
||||
@@ -395,7 +470,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/amd64/drone-gcr ./cmd/drone-gcr"
|
||||
environment:
|
||||
@@ -405,7 +481,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/gcr/Dockerfile.linux.amd64
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/gcr
|
||||
tags: linux-amd64
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -441,7 +535,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/arm64/drone-gcr ./cmd/drone-gcr"
|
||||
environment:
|
||||
@@ -453,7 +548,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/arm64/drone-gcr ./cmd/drone-gcr"
|
||||
environment:
|
||||
@@ -463,7 +559,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/gcr/Dockerfile.linux.arm64
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/gcr
|
||||
tags: linux-arm64
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -499,7 +613,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/arm/drone-gcr ./cmd/drone-gcr"
|
||||
environment:
|
||||
@@ -511,7 +626,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/arm/drone-gcr ./cmd/drone-gcr"
|
||||
environment:
|
||||
@@ -521,7 +637,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/gcr/Dockerfile.linux.arm
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/gcr
|
||||
tags: linux-arm
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -557,6 +691,7 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: manifest
|
||||
pull: always
|
||||
image: plugins/manifest
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -567,6 +702,14 @@ steps:
|
||||
username:
|
||||
from_secret: docker_username
|
||||
|
||||
- name: microbadger
|
||||
pull: always
|
||||
image: plugins/webhook
|
||||
failure: ignore
|
||||
settings:
|
||||
urls:
|
||||
from_secret: microbadger_gcr
|
||||
|
||||
trigger:
|
||||
ref:
|
||||
- refs/heads/master
|
||||
@@ -587,7 +730,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/amd64/drone-ecr ./cmd/drone-ecr"
|
||||
environment:
|
||||
@@ -599,7 +743,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/amd64/drone-ecr ./cmd/drone-ecr"
|
||||
environment:
|
||||
@@ -609,7 +754,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/ecr/Dockerfile.linux.amd64
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/ecr
|
||||
tags: linux-amd64
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -645,7 +808,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/arm64/drone-ecr ./cmd/drone-ecr"
|
||||
environment:
|
||||
@@ -657,7 +821,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/arm64/drone-ecr ./cmd/drone-ecr"
|
||||
environment:
|
||||
@@ -667,7 +832,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/ecr/Dockerfile.linux.arm64
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/ecr
|
||||
tags: linux-arm64
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -703,7 +886,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/arm/drone-ecr ./cmd/drone-ecr"
|
||||
environment:
|
||||
@@ -715,7 +899,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/arm/drone-ecr ./cmd/drone-ecr"
|
||||
environment:
|
||||
@@ -725,7 +910,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/ecr/Dockerfile.linux.arm
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/ecr
|
||||
tags: linux-arm
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -761,6 +964,7 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: manifest
|
||||
pull: always
|
||||
image: plugins/manifest
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -771,6 +975,14 @@ steps:
|
||||
username:
|
||||
from_secret: docker_username
|
||||
|
||||
- name: microbadger
|
||||
pull: always
|
||||
image: plugins/webhook
|
||||
failure: ignore
|
||||
settings:
|
||||
urls:
|
||||
from_secret: microbadger_ecr
|
||||
|
||||
trigger:
|
||||
ref:
|
||||
- refs/heads/master
|
||||
@@ -791,7 +1003,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/amd64/drone-heroku ./cmd/drone-heroku"
|
||||
environment:
|
||||
@@ -803,7 +1016,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/amd64/drone-heroku ./cmd/drone-heroku"
|
||||
environment:
|
||||
@@ -813,7 +1027,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/heroku/Dockerfile.linux.amd64
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/heroku
|
||||
tags: linux-amd64
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -849,7 +1081,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/arm64/drone-heroku ./cmd/drone-heroku"
|
||||
environment:
|
||||
@@ -861,7 +1094,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/arm64/drone-heroku ./cmd/drone-heroku"
|
||||
environment:
|
||||
@@ -871,7 +1105,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/heroku/Dockerfile.linux.arm64
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/heroku
|
||||
tags: linux-arm64
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -907,7 +1159,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_COMMIT_SHA:0:8}\" -a -tags netgo -o release/linux/arm/drone-heroku ./cmd/drone-heroku"
|
||||
environment:
|
||||
@@ -919,7 +1172,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v}\" -a -tags netgo -o release/linux/arm/drone-heroku ./cmd/drone-heroku"
|
||||
environment:
|
||||
@@ -929,7 +1183,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/heroku/Dockerfile.linux.arm
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/heroku
|
||||
tags: linux-arm
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -965,6 +1237,7 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: manifest
|
||||
pull: always
|
||||
image: plugins/manifest
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -975,6 +1248,14 @@ steps:
|
||||
username:
|
||||
from_secret: docker_username
|
||||
|
||||
- name: microbadger
|
||||
pull: always
|
||||
image: plugins/webhook
|
||||
failure: ignore
|
||||
settings:
|
||||
urls:
|
||||
from_secret: microbadger_heroku
|
||||
|
||||
trigger:
|
||||
ref:
|
||||
- refs/heads/master
|
||||
@@ -995,7 +1276,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.build=${DRONE_BUILD_NUMBER}\" -a -tags netgo -o release/linux/amd64/drone-acr ./cmd/drone-acr"
|
||||
environment:
|
||||
@@ -1007,7 +1289,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v} -X main.build=${DRONE_BUILD_NUMBER}\" -a -tags netgo -o release/linux/amd64/drone-acr ./cmd/drone-acr"
|
||||
environment:
|
||||
@@ -1017,7 +1300,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/acr/Dockerfile.linux.amd64
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/acr
|
||||
tags: linux-amd64
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -1053,7 +1354,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.build=${DRONE_BUILD_NUMBER}\" -a -tags netgo -o release/linux/arm64/drone-acr ./cmd/drone-acr"
|
||||
environment:
|
||||
@@ -1065,7 +1367,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v} -X main.build=${DRONE_BUILD_NUMBER}\" -a -tags netgo -o release/linux/arm64/drone-acr ./cmd/drone-acr"
|
||||
environment:
|
||||
@@ -1075,7 +1378,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/acr/Dockerfile.linux.arm64
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/acr
|
||||
tags: linux-arm64
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -1111,7 +1432,8 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: build-push
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.build=${DRONE_BUILD_NUMBER}\" -a -tags netgo -o release/linux/arm/drone-acr ./cmd/drone-acr"
|
||||
environment:
|
||||
@@ -1123,7 +1445,8 @@ steps:
|
||||
- tag
|
||||
|
||||
- name: build-tag
|
||||
image: golang:1.13
|
||||
pull: always
|
||||
image: golang:1.11
|
||||
commands:
|
||||
- "go build -v -ldflags \"-X main.version=${DRONE_TAG##v} -X main.build=${DRONE_BUILD_NUMBER}\" -a -tags netgo -o release/linux/arm/drone-acr ./cmd/drone-acr"
|
||||
environment:
|
||||
@@ -1133,7 +1456,25 @@ steps:
|
||||
event:
|
||||
- tag
|
||||
|
||||
- name: dryrun
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
daemon_off: false
|
||||
dockerfile: docker/acr/Dockerfile.linux.arm
|
||||
dry_run: true
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: plugins/acr
|
||||
tags: linux-arm
|
||||
username:
|
||||
from_secret: docker_username
|
||||
when:
|
||||
event:
|
||||
- pull_request
|
||||
|
||||
- name: publish
|
||||
pull: always
|
||||
image: plugins/docker:18
|
||||
settings:
|
||||
auto_tag: true
|
||||
@@ -1169,6 +1510,7 @@ platform:
|
||||
|
||||
steps:
|
||||
- name: manifest
|
||||
pull: always
|
||||
image: plugins/manifest
|
||||
settings:
|
||||
ignore_missing: true
|
||||
@@ -1178,6 +1520,14 @@ steps:
|
||||
username:
|
||||
from_secret: docker_username
|
||||
|
||||
- name: microbadger
|
||||
pull: always
|
||||
image: plugins/webhook
|
||||
failure: ignore
|
||||
settings:
|
||||
url:
|
||||
from_secret: microbadger_acr
|
||||
|
||||
trigger:
|
||||
ref:
|
||||
- refs/heads/master
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
since-tag=v19.03.8
|
||||
|
||||
25
CHANGELOG.md
25
CHANGELOG.md
@@ -1,25 +0,0 @@
|
||||
# Changelog
|
||||
|
||||
## [v19.03.9](https://github.com/drone-plugins/drone-docker/tree/v19.03.9) (2021-10-13)
|
||||
|
||||
[Full Changelog](https://github.com/drone-plugins/drone-docker/compare/v19.03.8...v19.03.9)
|
||||
|
||||
**Implemented enhancements:**
|
||||
|
||||
- adding support for externalId [\#333](https://github.com/drone-plugins/drone-docker/pull/333) ([jimsheldon](https://github.com/jimsheldon))
|
||||
- Add support for automatic opencontainer labels [\#313](https://github.com/drone-plugins/drone-docker/pull/313) ([codrut-fc](https://github.com/codrut-fc))
|
||||
- add custom seccomp profile [\#312](https://github.com/drone-plugins/drone-docker/pull/312) ([xoxys](https://github.com/xoxys))
|
||||
- ECR: adding setting to enable image scanning while repo creation [\#300](https://github.com/drone-plugins/drone-docker/pull/300) ([rvoitenko](https://github.com/rvoitenko))
|
||||
|
||||
**Fixed bugs:**
|
||||
|
||||
- Revert "Update seccomp to 20.10 docker" [\#325](https://github.com/drone-plugins/drone-docker/pull/325) ([bradrydzewski](https://github.com/bradrydzewski))
|
||||
|
||||
**Merged pull requests:**
|
||||
|
||||
- \(maint\) CI, remove the dry run steps, due to rate limiting [\#323](https://github.com/drone-plugins/drone-docker/pull/323) ([tphoney](https://github.com/tphoney))
|
||||
- Update seccomp to 20.10 docker [\#322](https://github.com/drone-plugins/drone-docker/pull/322) ([techknowlogick](https://github.com/techknowlogick))
|
||||
|
||||
|
||||
|
||||
\* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/github-changelog-generator/github-changelog-generator)*
|
||||
@@ -50,7 +50,7 @@ func main() {
|
||||
cli.StringFlag{
|
||||
Name: "daemon.mirror",
|
||||
Usage: "docker daemon registry mirror",
|
||||
EnvVar: "PLUGIN_MIRROR,DOCKER_PLUGIN_MIRROR",
|
||||
EnvVar: "PLUGIN_MIRROR",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "daemon.storage-driver",
|
||||
@@ -192,16 +192,6 @@ func main() {
|
||||
Usage: "label-schema labels",
|
||||
EnvVar: "PLUGIN_LABEL_SCHEMA",
|
||||
},
|
||||
cli.BoolTFlag{
|
||||
Name: "auto-label",
|
||||
Usage: "auto-label true|false",
|
||||
EnvVar: "PLUGIN_AUTO_LABEL",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "link",
|
||||
Usage: "link https://example.com/org/repo-name",
|
||||
EnvVar: "PLUGIN_REPO_LINK,DRONE_REPO_LINK",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "docker.registry",
|
||||
Usage: "docker registry",
|
||||
@@ -226,7 +216,7 @@ func main() {
|
||||
cli.StringFlag{
|
||||
Name: "docker.config",
|
||||
Usage: "docker json dockerconfig content",
|
||||
EnvVar: "PLUGIN_CONFIG,DOCKER_PLUGIN_CONFIG",
|
||||
EnvVar: "PLUGIN_CONFIG",
|
||||
},
|
||||
cli.BoolTFlag{
|
||||
Name: "docker.purge",
|
||||
@@ -267,26 +257,24 @@ func run(c *cli.Context) error {
|
||||
Config: c.String("docker.config"),
|
||||
},
|
||||
Build: docker.Build{
|
||||
Remote: c.String("remote.url"),
|
||||
Name: c.String("commit.sha"),
|
||||
Dockerfile: c.String("dockerfile"),
|
||||
Context: c.String("context"),
|
||||
Tags: c.StringSlice("tags"),
|
||||
Args: c.StringSlice("args"),
|
||||
ArgsEnv: c.StringSlice("args-from-env"),
|
||||
Target: c.String("target"),
|
||||
Squash: c.Bool("squash"),
|
||||
Pull: c.BoolT("pull-image"),
|
||||
CacheFrom: c.StringSlice("cache-from"),
|
||||
Compress: c.Bool("compress"),
|
||||
Repo: c.String("repo"),
|
||||
Labels: c.StringSlice("custom-labels"),
|
||||
LabelSchema: c.StringSlice("label-schema"),
|
||||
AutoLabel: c.BoolT("auto-label"),
|
||||
Link: c.String("link"),
|
||||
NoCache: c.Bool("no-cache"),
|
||||
AddHost: c.StringSlice("add-host"),
|
||||
Quiet: c.Bool("quiet"),
|
||||
Remote: c.String("remote.url"),
|
||||
Name: c.String("commit.sha"),
|
||||
Dockerfile: c.String("dockerfile"),
|
||||
Context: c.String("context"),
|
||||
Tags: c.StringSlice("tags"),
|
||||
Args: c.StringSlice("args"),
|
||||
ArgsEnv: c.StringSlice("args-from-env"),
|
||||
Target: c.String("target"),
|
||||
Squash: c.Bool("squash"),
|
||||
Pull: c.BoolT("pull-image"),
|
||||
CacheFrom: c.StringSlice("cache-from"),
|
||||
Compress: c.Bool("compress"),
|
||||
Repo: c.String("repo"),
|
||||
Labels: c.StringSlice("custom-labels"),
|
||||
LabelSchema: c.StringSlice("label-schema"),
|
||||
NoCache: c.Bool("no-cache"),
|
||||
AddHost: c.StringSlice("add-host"),
|
||||
Quiet: c.Bool("quiet"),
|
||||
},
|
||||
Daemon: docker.Daemon{
|
||||
Registry: c.String("docker.registry"),
|
||||
|
||||
@@ -37,8 +37,6 @@ func main() {
|
||||
lifecyclePolicy = getenv("PLUGIN_LIFECYCLE_POLICY")
|
||||
repositoryPolicy = getenv("PLUGIN_REPOSITORY_POLICY")
|
||||
assumeRole = getenv("PLUGIN_ASSUME_ROLE")
|
||||
externalId = getenv("PLUGIN_EXTERNAL_ID")
|
||||
scanOnPush = parseBoolOrDefault(false, getenv("PLUGIN_SCAN_ON_PUSH"))
|
||||
)
|
||||
|
||||
// set the region
|
||||
@@ -58,7 +56,7 @@ func main() {
|
||||
log.Fatal(fmt.Sprintf("error creating aws session: %v", err))
|
||||
}
|
||||
|
||||
svc := getECRClient(sess, assumeRole, externalId)
|
||||
svc := getECRClient(sess, assumeRole)
|
||||
username, password, defaultRegistry, err := getAuthInfo(svc)
|
||||
|
||||
if registry == "" {
|
||||
@@ -74,14 +72,10 @@ func main() {
|
||||
}
|
||||
|
||||
if create {
|
||||
err = ensureRepoExists(svc, trimHostname(repo, registry), scanOnPush)
|
||||
err = ensureRepoExists(svc, trimHostname(repo, registry))
|
||||
if err != nil {
|
||||
log.Fatal(fmt.Sprintf("error creating ECR repo: %v", err))
|
||||
}
|
||||
err = updateImageScannningConfig(svc, trimHostname(repo, registry), scanOnPush)
|
||||
if err != nil {
|
||||
log.Fatal(fmt.Sprintf("error updating scan on push for ECR repo: %v", err))
|
||||
}
|
||||
}
|
||||
|
||||
if lifecyclePolicy != "" {
|
||||
@@ -124,10 +118,9 @@ func trimHostname(repo, registry string) string {
|
||||
return repo
|
||||
}
|
||||
|
||||
func ensureRepoExists(svc *ecr.ECR, name string, scanOnPush bool) (err error) {
|
||||
func ensureRepoExists(svc *ecr.ECR, name string) (err error) {
|
||||
input := &ecr.CreateRepositoryInput{}
|
||||
input.SetRepositoryName(name)
|
||||
input.SetImageScanningConfiguration(&ecr.ImageScanningConfiguration{ScanOnPush: &scanOnPush})
|
||||
_, err = svc.CreateRepository(input)
|
||||
if err != nil {
|
||||
if aerr, ok := err.(awserr.Error); ok && aerr.Code() == ecr.ErrCodeRepositoryAlreadyExistsException {
|
||||
@@ -139,15 +132,6 @@ func ensureRepoExists(svc *ecr.ECR, name string, scanOnPush bool) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func updateImageScannningConfig(svc *ecr.ECR, name string, scanOnPush bool) (err error) {
|
||||
input := &ecr.PutImageScanningConfigurationInput{}
|
||||
input.SetRepositoryName(name)
|
||||
input.SetImageScanningConfiguration(&ecr.ImageScanningConfiguration{ScanOnPush: &scanOnPush})
|
||||
_, err = svc.PutImageScanningConfiguration(input)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
func uploadLifeCyclePolicy(svc *ecr.ECR, lifecyclePolicy string, name string) (err error) {
|
||||
input := &ecr.PutLifecyclePolicyInput{}
|
||||
input.SetLifecyclePolicyText(lifecyclePolicy)
|
||||
@@ -209,19 +193,11 @@ func getenv(key ...string) (s string) {
|
||||
return
|
||||
}
|
||||
|
||||
func getECRClient(sess *session.Session, role string, externalId string) *ecr.ECR {
|
||||
func getECRClient(sess *session.Session, role string) *ecr.ECR {
|
||||
if role == "" {
|
||||
return ecr.New(sess)
|
||||
}
|
||||
if externalId != "" {
|
||||
return ecr.New(sess, &aws.Config{
|
||||
Credentials: stscreds.NewCredentials(sess, role, func(p *stscreds.AssumeRoleProvider) {
|
||||
p.ExternalID = &externalId
|
||||
}),
|
||||
})
|
||||
} else {
|
||||
return ecr.New(sess, &aws.Config{
|
||||
Credentials: stscreds.NewCredentials(sess, role),
|
||||
})
|
||||
}
|
||||
return ecr.New(sess, &aws.Config{
|
||||
Credentials: stscreds.NewCredentials(sess, role),
|
||||
})
|
||||
}
|
||||
|
||||
71
docker.go
71
docker.go
@@ -53,9 +53,7 @@ type (
|
||||
Compress bool // Docker build compress
|
||||
Repo string // Docker build repository
|
||||
LabelSchema []string // label-schema Label map
|
||||
AutoLabel bool // auto-label bool
|
||||
Labels []string // Label map
|
||||
Link string // Git repo link
|
||||
NoCache bool // Docker build no-cache
|
||||
AddHost []string // Docker build add-host
|
||||
Quiet bool // Docker build quiet
|
||||
@@ -80,55 +78,44 @@ func (p Plugin) Exec() error {
|
||||
|
||||
// poll the docker daemon until it is started. This ensures the daemon is
|
||||
// ready to accept connections before we proceed.
|
||||
for i := 0; ; i++ {
|
||||
for i := 0; i < 15; i++ {
|
||||
cmd := commandInfo()
|
||||
err := cmd.Run()
|
||||
if err == nil {
|
||||
break
|
||||
}
|
||||
if i == 15 {
|
||||
fmt.Println("Unable to reach Docker Daemon after 15 attempts.")
|
||||
break
|
||||
}
|
||||
time.Sleep(time.Second * 1)
|
||||
}
|
||||
|
||||
// for debugging purposes, log the type of authentication
|
||||
// credentials that have been provided.
|
||||
switch {
|
||||
case p.Login.Password != "" && p.Login.Config != "":
|
||||
fmt.Println("Detected registry credentials and registry credentials file")
|
||||
case p.Login.Password != "":
|
||||
fmt.Println("Detected registry credentials")
|
||||
case p.Login.Config != "":
|
||||
fmt.Println("Detected registry credentials file")
|
||||
default:
|
||||
fmt.Println("Registry credentials or Docker config not provided. Guest mode enabled.")
|
||||
}
|
||||
|
||||
// create Auth Config File
|
||||
// Create Auth Config File
|
||||
if p.Login.Config != "" {
|
||||
os.MkdirAll(dockerHome, 0600)
|
||||
|
||||
path := filepath.Join(dockerHome, "config.json")
|
||||
err := ioutil.WriteFile(path, []byte(p.Login.Config), 0600)
|
||||
if err != nil {
|
||||
return fmt.Errorf("Error writing config.json: %s", err)
|
||||
return fmt.Errorf("Error writeing config.json: %s", err)
|
||||
}
|
||||
}
|
||||
|
||||
// login to the Docker registry
|
||||
if p.Login.Password != "" {
|
||||
cmd := commandLogin(p.Login)
|
||||
raw, err := cmd.CombinedOutput()
|
||||
err := cmd.Run()
|
||||
if err != nil {
|
||||
out := string(raw)
|
||||
out = strings.Replace(out, "WARNING! Using --password via the CLI is insecure. Use --password-stdin.", "", -1)
|
||||
fmt.Println(out)
|
||||
return fmt.Errorf("Error authenticating: exit status 1")
|
||||
return fmt.Errorf("Error authenticating: %s", err)
|
||||
}
|
||||
}
|
||||
|
||||
switch {
|
||||
case p.Login.Password != "":
|
||||
fmt.Println("Detected registry credentials")
|
||||
case p.Login.Config != "":
|
||||
fmt.Println("Detected registry credentials file")
|
||||
default:
|
||||
fmt.Println("Registry credentials or Docker config not provided. Guest mode enabled.")
|
||||
}
|
||||
|
||||
if p.Build.Squash && !p.Daemon.Experimental {
|
||||
fmt.Println("Squash build flag is only available when Docker deamon is started with experimental flag. Ignoring...")
|
||||
p.Build.Squash = false
|
||||
@@ -265,22 +252,19 @@ func commandBuild(build Build) *exec.Cmd {
|
||||
args = append(args, "--quiet")
|
||||
}
|
||||
|
||||
if build.AutoLabel {
|
||||
labelSchema := []string{
|
||||
fmt.Sprintf("created=%s", time.Now().Format(time.RFC3339)),
|
||||
fmt.Sprintf("revision=%s", build.Name),
|
||||
fmt.Sprintf("source=%s", build.Remote),
|
||||
fmt.Sprintf("url=%s", build.Link),
|
||||
}
|
||||
labelPrefix := "org.opencontainers.image"
|
||||
labelSchema := []string{
|
||||
"schema-version=1.0",
|
||||
fmt.Sprintf("build-date=%s", time.Now().Format(time.RFC3339)),
|
||||
fmt.Sprintf("vcs-ref=%s", build.Name),
|
||||
fmt.Sprintf("vcs-url=%s", build.Remote),
|
||||
}
|
||||
|
||||
if len(build.LabelSchema) > 0 {
|
||||
labelSchema = append(labelSchema, build.LabelSchema...)
|
||||
}
|
||||
if len(build.LabelSchema) > 0 {
|
||||
labelSchema = append(labelSchema, build.LabelSchema...)
|
||||
}
|
||||
|
||||
for _, label := range labelSchema {
|
||||
args = append(args, "--label", fmt.Sprintf("%s.%s", labelPrefix, label))
|
||||
}
|
||||
for _, label := range labelSchema {
|
||||
args = append(args, "--label", fmt.Sprintf("org.label-schema.%s", label))
|
||||
}
|
||||
|
||||
if len(build.Labels) > 0 {
|
||||
@@ -359,10 +343,6 @@ func commandDaemon(daemon Daemon) *exec.Cmd {
|
||||
"--host=unix:///var/run/docker.sock",
|
||||
}
|
||||
|
||||
if _, err := os.Stat("/etc/docker/default.json"); err == nil {
|
||||
args = append(args, "--seccomp-profile=/etc/docker/default.json")
|
||||
}
|
||||
|
||||
if daemon.StorageDriver != "" {
|
||||
args = append(args, "-s", daemon.StorageDriver)
|
||||
}
|
||||
@@ -393,6 +373,7 @@ func commandDaemon(daemon Daemon) *exec.Cmd {
|
||||
return exec.Command(dockerdExe, args...)
|
||||
}
|
||||
|
||||
|
||||
// helper to check if args match "docker prune"
|
||||
func isCommandPrune(args []string) bool {
|
||||
return len(args) > 3 && args[2] == "prune"
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-1809
|
||||
FROM plugins/docker:windows-1809-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone ACR" `
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-1803
|
||||
FROM plugins/docker:windows-1903-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone ACR" `
|
||||
10
docker/acr/Dockerfile.windows.1909
Normal file
10
docker/acr/Dockerfile.windows.1909
Normal file
@@ -0,0 +1,10 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-1909-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone ACR" `
|
||||
org.label-schema.vendor="Drone.IO Community" `
|
||||
org.label-schema.schema-version="1.0"
|
||||
|
||||
ADD release/windows/amd64/drone-acr.exe C:/bin/drone-acr.exe
|
||||
ENTRYPOINT [ "C:\\bin\\drone-acr.exe" ]
|
||||
10
docker/acr/Dockerfile.windows.2004
Normal file
10
docker/acr/Dockerfile.windows.2004
Normal file
@@ -0,0 +1,10 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-2004-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone ACR" `
|
||||
org.label-schema.vendor="Drone.IO Community" `
|
||||
org.label-schema.schema-version="1.0"
|
||||
|
||||
ADD release/windows/amd64/drone-acr.exe C:/bin/drone-acr.exe
|
||||
ENTRYPOINT [ "C:\\bin\\drone-acr.exe" ]
|
||||
@@ -1,36 +1,43 @@
|
||||
image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}latest{{/if}}
|
||||
|
||||
{{#if build.tags}}
|
||||
tags:
|
||||
{{#each build.tags}}
|
||||
- {{this}}
|
||||
{{/each}}
|
||||
{{/if}}
|
||||
|
||||
manifests:
|
||||
-
|
||||
image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-amd64
|
||||
- image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: linux
|
||||
-
|
||||
image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm64
|
||||
- image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm64
|
||||
platform:
|
||||
architecture: arm64
|
||||
os: linux
|
||||
variant: v8
|
||||
-
|
||||
image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm
|
||||
- image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm
|
||||
platform:
|
||||
architecture: arm
|
||||
os: linux
|
||||
variant: v7
|
||||
-
|
||||
image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1803
|
||||
- image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-2004-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1803
|
||||
-
|
||||
image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1809
|
||||
version: 2004
|
||||
- image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1909-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1909
|
||||
- image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1903-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1903
|
||||
- image: plugins/acr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1809-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
|
||||
@@ -2,14 +2,5 @@ FROM arm32v6/docker:19.03.8-dind
|
||||
|
||||
ENV DOCKER_HOST=unix:///var/run/docker.sock
|
||||
|
||||
RUN apk --update add --virtual .build-deps curl && \
|
||||
mkdir -p /etc/docker/ && \
|
||||
curl -SsL -o /etc/docker/default.json https://raw.githubusercontent.com/moby/moby/19.03/profiles/seccomp/default.json && \
|
||||
sed -i 's/SCMP_ACT_ERRNO/SCMP_ACT_TRACE/g' /etc/docker/default.json && \
|
||||
chmod 600 /etc/docker/default.json && \
|
||||
apk del .build-deps && \
|
||||
rm -rf /var/cache/apk/* && \
|
||||
rm -rf /tmp/*
|
||||
|
||||
ADD release/linux/arm/drone-docker /bin/
|
||||
ENTRYPOINT ["/usr/local/bin/dockerd-entrypoint.sh", "/bin/drone-docker"]
|
||||
|
||||
@@ -3,9 +3,9 @@ FROM mcr.microsoft.com/windows/servercore:1809 as download
|
||||
|
||||
SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]
|
||||
|
||||
ENV DOCKER_VERSION 18.09.1
|
||||
ENV DOCKER_VERSION 19.03.1
|
||||
|
||||
RUN Invoke-WebRequest 'http://constexpr.org/innoextract/files/innoextract-1.6-windows.zip' -OutFile 'innoextract.zip' -UseBasicParsing ; `
|
||||
RUN Invoke-WebRequest 'http://constexpr.org/innoextract/files/innoextract-1.9-windows.zip' -OutFile 'innoextract.zip' -UseBasicParsing ; `
|
||||
Expand-Archive innoextract.zip -DestinationPath C:\ ; `
|
||||
Remove-Item -Path innoextract.zip
|
||||
|
||||
@@ -13,7 +13,7 @@ RUN [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tl
|
||||
Invoke-WebRequest $('https://github.com/docker/toolbox/releases/download/v{0}/DockerToolbox-{0}.exe' -f $env:DOCKER_VERSION) -OutFile 'dockertoolbox.exe' -UseBasicParsing
|
||||
RUN /innoextract.exe dockertoolbox.exe
|
||||
|
||||
FROM mcr.microsoft.com/windows/nanoserver:1809
|
||||
FROM plugins/base:windows-1809-amd64
|
||||
USER ContainerAdministrator
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
|
||||
@@ -5,7 +5,7 @@ SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPref
|
||||
|
||||
ENV DOCKER_VERSION 19.03.1
|
||||
|
||||
RUN Invoke-WebRequest 'http://constexpr.org/innoextract/files/innoextract-1.7-windows.zip' -OutFile 'innoextract.zip' -UseBasicParsing ; `
|
||||
RUN Invoke-WebRequest 'http://constexpr.org/innoextract/files/innoextract-1.9-windows.zip' -OutFile 'innoextract.zip' -UseBasicParsing ; `
|
||||
Expand-Archive innoextract.zip -DestinationPath C:\ ; `
|
||||
Remove-Item -Path innoextract.zip
|
||||
|
||||
@@ -13,7 +13,7 @@ RUN [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tl
|
||||
Invoke-WebRequest $('https://github.com/docker/toolbox/releases/download/v{0}/DockerToolbox-{0}.exe' -f $env:DOCKER_VERSION) -OutFile 'dockertoolbox.exe' -UseBasicParsing
|
||||
RUN /innoextract.exe dockertoolbox.exe
|
||||
|
||||
FROM mcr.microsoft.com/windows/nanoserver:1903
|
||||
FROM plugins/base:windows-1903-amd64
|
||||
USER ContainerAdministrator
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
@@ -21,7 +21,6 @@ LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.vendor="Drone.IO Community" `
|
||||
org.label-schema.schema-version="1.0"
|
||||
|
||||
RUN mkdir C:\bin
|
||||
COPY --from=download /windows/system32/netapi32.dll /windows/system32/netapi32.dll
|
||||
COPY --from=download /app/docker.exe C:/bin/docker.exe
|
||||
ADD release/windows/amd64/drone-docker.exe C:/bin/drone-docker.exe
|
||||
|
||||
@@ -5,7 +5,7 @@ SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPref
|
||||
|
||||
ENV DOCKER_VERSION 19.03.1
|
||||
|
||||
RUN Invoke-WebRequest 'http://constexpr.org/innoextract/files/innoextract-1.7-windows.zip' -OutFile 'innoextract.zip' -UseBasicParsing ; `
|
||||
RUN Invoke-WebRequest 'http://constexpr.org/innoextract/files/innoextract-1.9-windows.zip' -OutFile 'innoextract.zip' -UseBasicParsing ; `
|
||||
Expand-Archive innoextract.zip -DestinationPath C:\ ; `
|
||||
Remove-Item -Path innoextract.zip
|
||||
|
||||
@@ -13,7 +13,7 @@ RUN [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tl
|
||||
Invoke-WebRequest $('https://github.com/docker/toolbox/releases/download/v{0}/DockerToolbox-{0}.exe' -f $env:DOCKER_VERSION) -OutFile 'dockertoolbox.exe' -UseBasicParsing
|
||||
RUN /innoextract.exe dockertoolbox.exe
|
||||
|
||||
FROM mcr.microsoft.com/windows/nanoserver:1909
|
||||
FROM plugins/base:windows-1909-amd64
|
||||
USER ContainerAdministrator
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
@@ -21,7 +21,6 @@ LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.vendor="Drone.IO Community" `
|
||||
org.label-schema.schema-version="1.0"
|
||||
|
||||
RUN mkdir C:\bin
|
||||
COPY --from=download /windows/system32/netapi32.dll /windows/system32/netapi32.dll
|
||||
COPY --from=download /app/docker.exe C:/bin/docker.exe
|
||||
ADD release/windows/amd64/drone-docker.exe C:/bin/drone-docker.exe
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
# escape=`
|
||||
FROM mcr.microsoft.com/windows/servercore:1803 as download
|
||||
FROM mcr.microsoft.com/windows/servercore:2004 as download
|
||||
|
||||
SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]
|
||||
|
||||
ENV DOCKER_VERSION 18.09.1
|
||||
ENV DOCKER_VERSION 19.03.1
|
||||
|
||||
RUN Invoke-WebRequest 'http://constexpr.org/innoextract/files/innoextract-1.6-windows.zip' -OutFile 'innoextract.zip' -UseBasicParsing ; `
|
||||
RUN Invoke-WebRequest 'http://constexpr.org/innoextract/files/innoextract-1.9-windows.zip' -OutFile 'innoextract.zip' -UseBasicParsing ; `
|
||||
Expand-Archive innoextract.zip -DestinationPath C:\ ; `
|
||||
Remove-Item -Path innoextract.zip
|
||||
|
||||
@@ -13,7 +13,8 @@ RUN [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tl
|
||||
Invoke-WebRequest $('https://github.com/docker/toolbox/releases/download/v{0}/DockerToolbox-{0}.exe' -f $env:DOCKER_VERSION) -OutFile 'dockertoolbox.exe' -UseBasicParsing
|
||||
RUN /innoextract.exe dockertoolbox.exe
|
||||
|
||||
FROM plugins/base:windows-1803
|
||||
FROM plugins/base:windows-2004-amd64
|
||||
USER ContainerAdministrator
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone Docker" `
|
||||
@@ -1,49 +1,44 @@
|
||||
image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}latest{{/if}}
|
||||
|
||||
{{#if build.tags}}
|
||||
tags:
|
||||
{{#each build.tags}}
|
||||
- {{this}}
|
||||
{{/each}}
|
||||
{{/if}}
|
||||
|
||||
manifests:
|
||||
-
|
||||
image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-amd64
|
||||
- image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: linux
|
||||
-
|
||||
image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm64
|
||||
- image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm64
|
||||
platform:
|
||||
architecture: arm64
|
||||
os: linux
|
||||
variant: v8
|
||||
-
|
||||
image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm
|
||||
- image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm
|
||||
platform:
|
||||
architecture: arm
|
||||
os: linux
|
||||
variant: v7
|
||||
-
|
||||
image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1803
|
||||
- image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-2004-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1803
|
||||
-
|
||||
image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1809-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1809
|
||||
-
|
||||
image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1903-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1903
|
||||
-
|
||||
image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1909-amd64
|
||||
version: 2004
|
||||
- image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1909-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1909
|
||||
- image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1903-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1903
|
||||
- image: plugins/docker:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1809-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1809
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-1809
|
||||
FROM plugins/docker:windows-1809-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone ECR" `
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-1803
|
||||
FROM plugins/docker:windows-1903-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone ECR" `
|
||||
10
docker/ecr/Dockerfile.windows.1909
Normal file
10
docker/ecr/Dockerfile.windows.1909
Normal file
@@ -0,0 +1,10 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-1909-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone ECR" `
|
||||
org.label-schema.vendor="Drone.IO Community" `
|
||||
org.label-schema.schema-version="1.0"
|
||||
|
||||
ADD release/windows/amd64/drone-ecr.exe C:/bin/drone-ecr.exe
|
||||
ENTRYPOINT [ "C:\\bin\\drone-ecr.exe" ]
|
||||
10
docker/ecr/Dockerfile.windows.2004
Normal file
10
docker/ecr/Dockerfile.windows.2004
Normal file
@@ -0,0 +1,10 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-2004-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone ECR" `
|
||||
org.label-schema.vendor="Drone.IO Community" `
|
||||
org.label-schema.schema-version="1.0"
|
||||
|
||||
ADD release/windows/amd64/drone-ecr.exe C:/bin/drone-ecr.exe
|
||||
ENTRYPOINT [ "C:\\bin\\drone-ecr.exe" ]
|
||||
@@ -1,36 +1,43 @@
|
||||
image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}latest{{/if}}
|
||||
|
||||
{{#if build.tags}}
|
||||
tags:
|
||||
{{#each build.tags}}
|
||||
- {{this}}
|
||||
{{/each}}
|
||||
{{/if}}
|
||||
|
||||
manifests:
|
||||
-
|
||||
image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-amd64
|
||||
- image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: linux
|
||||
-
|
||||
image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm64
|
||||
- image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm64
|
||||
platform:
|
||||
architecture: arm64
|
||||
os: linux
|
||||
variant: v8
|
||||
-
|
||||
image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm
|
||||
- image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm
|
||||
platform:
|
||||
architecture: arm
|
||||
os: linux
|
||||
variant: v7
|
||||
-
|
||||
image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1803
|
||||
- image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-2004-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1803
|
||||
-
|
||||
image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1809
|
||||
version: 2004
|
||||
- image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1909-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1909
|
||||
- image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1903-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1903
|
||||
- image: plugins/ecr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1809-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-1809
|
||||
FROM plugins/docker:windows-1809-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone GCR" `
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-1803
|
||||
FROM plugins/docker:windows-1903-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone GCR" `
|
||||
10
docker/gcr/Dockerfile.windows.1909
Normal file
10
docker/gcr/Dockerfile.windows.1909
Normal file
@@ -0,0 +1,10 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-1909-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone GCR" `
|
||||
org.label-schema.vendor="Drone.IO Community" `
|
||||
org.label-schema.schema-version="1.0"
|
||||
|
||||
ADD release/windows/amd64/drone-gcr.exe C:/bin/drone-gcr.exe
|
||||
ENTRYPOINT [ "C:\\bin\\drone-gcr.exe" ]
|
||||
10
docker/gcr/Dockerfile.windows.2004
Normal file
10
docker/gcr/Dockerfile.windows.2004
Normal file
@@ -0,0 +1,10 @@
|
||||
# escape=`
|
||||
FROM plugins/docker:windows-2004-amd64
|
||||
|
||||
LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
|
||||
org.label-schema.name="Drone GCR" `
|
||||
org.label-schema.vendor="Drone.IO Community" `
|
||||
org.label-schema.schema-version="1.0"
|
||||
|
||||
ADD release/windows/amd64/drone-gcr.exe C:/bin/drone-gcr.exe
|
||||
ENTRYPOINT [ "C:\\bin\\drone-gcr.exe" ]
|
||||
@@ -1,36 +1,43 @@
|
||||
image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}latest{{/if}}
|
||||
|
||||
{{#if build.tags}}
|
||||
tags:
|
||||
{{#each build.tags}}
|
||||
- {{this}}
|
||||
{{/each}}
|
||||
{{/if}}
|
||||
|
||||
manifests:
|
||||
-
|
||||
image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-amd64
|
||||
- image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: linux
|
||||
-
|
||||
image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm64
|
||||
- image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm64
|
||||
platform:
|
||||
architecture: arm64
|
||||
os: linux
|
||||
variant: v8
|
||||
-
|
||||
image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm
|
||||
- image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm
|
||||
platform:
|
||||
architecture: arm
|
||||
os: linux
|
||||
variant: v7
|
||||
-
|
||||
image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1803
|
||||
- image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-2004-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1803
|
||||
-
|
||||
image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1809
|
||||
version: 2004
|
||||
- image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1909-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1909
|
||||
- image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1903-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
version: 1903
|
||||
- image: plugins/gcr:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1809-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: windows
|
||||
|
||||
@@ -1,24 +1,23 @@
|
||||
image: plugins/heroku:{{#if build.tag}}{{trimPrefix "v" build.tag}}{{else}}latest{{/if}}
|
||||
|
||||
{{#if build.tags}}
|
||||
tags:
|
||||
{{#each build.tags}}
|
||||
- {{this}}
|
||||
{{/each}}
|
||||
{{/if}}
|
||||
|
||||
manifests:
|
||||
-
|
||||
image: plugins/heroku:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-amd64
|
||||
- image: plugins/heroku:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-amd64
|
||||
platform:
|
||||
architecture: amd64
|
||||
os: linux
|
||||
-
|
||||
image: plugins/heroku:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm64
|
||||
- image: plugins/heroku:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm64
|
||||
platform:
|
||||
architecture: arm64
|
||||
os: linux
|
||||
variant: v8
|
||||
-
|
||||
image: plugins/heroku:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm
|
||||
- image: plugins/heroku:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}linux-arm
|
||||
platform:
|
||||
architecture: arm
|
||||
os: linux
|
||||
|
||||
@@ -5,7 +5,7 @@ local test_pipeline_name = 'testing';
|
||||
local windows(os) = os == 'windows';
|
||||
|
||||
local golang_image(os, version) =
|
||||
'golang:' + '1.13' + if windows(os) then '-windowsservercore-' + version else '';
|
||||
'golang:' + '1.11' + if windows(os) then '-windowsservercore-' + version else '';
|
||||
|
||||
{
|
||||
test(os='linux', arch='amd64', version='')::
|
||||
|
||||
Reference in New Issue
Block a user