0
0
mirror of https://github.com/thegeeklab/wp-github-comment.git synced 2024-11-09 17:50:38 +00:00

add dockerhub auth for ci

This commit is contained in:
Robert Kaussow 2020-11-28 13:50:39 +01:00
parent 3ef5be32e7
commit 2931248d85
No known key found for this signature in database
GPG Key ID: 65362AE74AF98B61
2 changed files with 56 additions and 13 deletions

View File

@ -1,5 +1,6 @@
local PipelineTest = {
kind: 'pipeline',
image_pull_secrets: ['docker_config'],
name: 'test',
platform: {
os: 'linux',
@ -73,6 +74,7 @@ local PipelineTest = {
local PipelineBuildBinaries = {
kind: 'pipeline',
image_pull_secrets: ['docker_config'],
name: 'build-binaries',
platform: {
os: 'linux',
@ -141,6 +143,7 @@ local PipelineBuildBinaries = {
local PipelineBuildContainer(arch='amd64') = {
kind: 'pipeline',
image_pull_secrets: ['docker_config'],
name: 'build-container-' + arch,
platform: {
os: 'linux',
@ -157,8 +160,9 @@ local PipelineBuildContainer(arch='amd64') = {
},
{
name: 'dryrun',
image: 'plugins/docker:18-linux-' + arch,
image: 'plugins/docker:19',
settings: {
config: { from_secret: 'docker_config' },
dry_run: true,
dockerfile: 'docker/Dockerfile.' + arch,
repo: 'thegeeklab/${DRONE_REPO_NAME}',
@ -172,8 +176,9 @@ local PipelineBuildContainer(arch='amd64') = {
},
{
name: 'publish-dockerhub',
image: 'plugins/docker:18-linux-' + arch,
image: 'plugins/docker:19',
settings: {
config: { from_secret: 'docker_config' },
auto_tag: true,
auto_tag_suffix: arch,
dockerfile: 'docker/Dockerfile.' + arch,
@ -188,8 +193,9 @@ local PipelineBuildContainer(arch='amd64') = {
},
{
name: 'publish-quay',
image: 'plugins/docker:18-linux-' + arch,
image: 'plugins/docker:19',
settings: {
config: { from_secret: 'docker_config' },
auto_tag: true,
auto_tag_suffix: arch,
dockerfile: 'docker/Dockerfile.' + arch,
@ -214,6 +220,7 @@ local PipelineBuildContainer(arch='amd64') = {
local PipelineNotifications = {
kind: 'pipeline',
image_pull_secrets: ['docker_config'],
name: 'notifications',
platform: {
os: 'linux',

View File

@ -43,6 +43,9 @@ volumes:
- name: gopath
temp: {}
image_pull_secrets:
- docker_config
trigger:
ref:
- refs/heads/master
@ -97,6 +100,9 @@ steps:
ref:
- refs/tags/**
image_pull_secrets:
- docker_config
trigger:
ref:
- refs/heads/master
@ -122,8 +128,10 @@ steps:
- go build -v -ldflags "-X main.version=$BUILD_VERSION" -a -tags netgo -o release/amd64/drone-github-comment ./cmd/drone-github-comment
- name: dryrun
image: plugins/docker:18-linux-amd64
image: plugins/docker:19
settings:
config:
from_secret: docker_config
dockerfile: docker/Dockerfile.amd64
dry_run: true
password:
@ -138,10 +146,12 @@ steps:
- build
- name: publish-dockerhub
image: plugins/docker:18-linux-amd64
image: plugins/docker:19
settings:
auto_tag: true
auto_tag_suffix: amd64
config:
from_secret: docker_config
dockerfile: docker/Dockerfile.amd64
password:
from_secret: docker_password
@ -156,10 +166,12 @@ steps:
- dryrun
- name: publish-quay
image: plugins/docker:18-linux-amd64
image: plugins/docker:19
settings:
auto_tag: true
auto_tag_suffix: amd64
config:
from_secret: docker_config
dockerfile: docker/Dockerfile.amd64
password:
from_secret: quay_password
@ -174,6 +186,9 @@ steps:
depends_on:
- dryrun
image_pull_secrets:
- docker_config
trigger:
ref:
- refs/heads/master
@ -199,8 +214,10 @@ steps:
- go build -v -ldflags "-X main.version=$BUILD_VERSION" -a -tags netgo -o release/arm64/drone-github-comment ./cmd/drone-github-comment
- name: dryrun
image: plugins/docker:18-linux-arm64
image: plugins/docker:19
settings:
config:
from_secret: docker_config
dockerfile: docker/Dockerfile.arm64
dry_run: true
password:
@ -215,10 +232,12 @@ steps:
- build
- name: publish-dockerhub
image: plugins/docker:18-linux-arm64
image: plugins/docker:19
settings:
auto_tag: true
auto_tag_suffix: arm64
config:
from_secret: docker_config
dockerfile: docker/Dockerfile.arm64
password:
from_secret: docker_password
@ -233,10 +252,12 @@ steps:
- dryrun
- name: publish-quay
image: plugins/docker:18-linux-arm64
image: plugins/docker:19
settings:
auto_tag: true
auto_tag_suffix: arm64
config:
from_secret: docker_config
dockerfile: docker/Dockerfile.arm64
password:
from_secret: quay_password
@ -251,6 +272,9 @@ steps:
depends_on:
- dryrun
image_pull_secrets:
- docker_config
trigger:
ref:
- refs/heads/master
@ -276,8 +300,10 @@ steps:
- go build -v -ldflags "-X main.version=$BUILD_VERSION" -a -tags netgo -o release/arm/drone-github-comment ./cmd/drone-github-comment
- name: dryrun
image: plugins/docker:18-linux-arm
image: plugins/docker:19
settings:
config:
from_secret: docker_config
dockerfile: docker/Dockerfile.arm
dry_run: true
password:
@ -292,10 +318,12 @@ steps:
- build
- name: publish-dockerhub
image: plugins/docker:18-linux-arm
image: plugins/docker:19
settings:
auto_tag: true
auto_tag_suffix: arm
config:
from_secret: docker_config
dockerfile: docker/Dockerfile.arm
password:
from_secret: docker_password
@ -310,10 +338,12 @@ steps:
- dryrun
- name: publish-quay
image: plugins/docker:18-linux-arm
image: plugins/docker:19
settings:
auto_tag: true
auto_tag_suffix: arm
config:
from_secret: docker_config
dockerfile: docker/Dockerfile.arm
password:
from_secret: quay_password
@ -328,6 +358,9 @@ steps:
depends_on:
- dryrun
image_pull_secrets:
- docker_config
trigger:
ref:
- refs/heads/master
@ -416,6 +449,9 @@ steps:
- success
- failure
image_pull_secrets:
- docker_config
trigger:
ref:
- refs/heads/master
@ -432,6 +468,6 @@ depends_on:
---
kind: signature
hmac: c475b26373c250eff194cba0fabfddb2047242a3cfb3250ab734a2dd4f92507e
hmac: 86fcc05f5bcfb7375d23185103d52209232fa92edd680298bd92a313d7eafb8c
...