add dockerhub auth for ci

This commit is contained in:
Robert Kaussow 2020-11-27 14:13:11 +01:00
parent bc4fbfc343
commit d33f66eaa0
No known key found for this signature in database
GPG Key ID: 65362AE74AF98B61
2 changed files with 57 additions and 13 deletions

View File

@ -18,6 +18,7 @@ local PythonVersion(pyversion='3.5') = {
local PipelineLint = { local PipelineLint = {
kind: 'pipeline', kind: 'pipeline',
image_pull_secrets: ['docker_config'],
name: 'lint', name: 'lint',
platform: { platform: {
os: 'linux', os: 'linux',
@ -45,6 +46,7 @@ local PipelineLint = {
local PipelineTest = { local PipelineTest = {
kind: 'pipeline', kind: 'pipeline',
image_pull_secrets: ['docker_config'],
name: 'test', name: 'test',
platform: { platform: {
os: 'linux', os: 'linux',
@ -67,6 +69,7 @@ local PipelineTest = {
local PipelineSecurity = { local PipelineSecurity = {
kind: 'pipeline', kind: 'pipeline',
image_pull_secrets: ['docker_config'],
name: 'security', name: 'security',
platform: { platform: {
os: 'linux', os: 'linux',
@ -97,6 +100,7 @@ local PipelineSecurity = {
local PipelineBuildPackage = { local PipelineBuildPackage = {
kind: 'pipeline', kind: 'pipeline',
image_pull_secrets: ['docker_config'],
name: 'build-package', name: 'build-package',
platform: { platform: {
os: 'linux', os: 'linux',
@ -155,6 +159,7 @@ local PipelineBuildPackage = {
local PipelineBuildContainer(arch='amd64') = { local PipelineBuildContainer(arch='amd64') = {
kind: 'pipeline', kind: 'pipeline',
image_pull_secrets: ['docker_config'],
name: 'build-container-' + arch, name: 'build-container-' + arch,
platform: { platform: {
os: 'linux', os: 'linux',
@ -171,7 +176,7 @@ local PipelineBuildContainer(arch='amd64') = {
}, },
{ {
name: 'dryrun', name: 'dryrun',
image: 'plugins/docker:18-linux-' + arch, image: 'plugins/docker:19',
pull: 'always', pull: 'always',
settings: { settings: {
dry_run: true, dry_run: true,
@ -187,8 +192,9 @@ local PipelineBuildContainer(arch='amd64') = {
}, },
{ {
name: 'publish-dockerhub', name: 'publish-dockerhub',
image: 'plugins/docker:18-linux-' + arch, image: 'plugins/docker:19',
settings: { settings: {
config: { from_secret: 'docker_config' },
auto_tag: true, auto_tag: true,
auto_tag_suffix: arch, auto_tag_suffix: arch,
dockerfile: 'docker/Dockerfile', dockerfile: 'docker/Dockerfile',
@ -203,8 +209,9 @@ local PipelineBuildContainer(arch='amd64') = {
}, },
{ {
name: 'publish-quay', name: 'publish-quay',
image: 'plugins/docker:18-linux-' + arch, image: 'plugins/docker:19',
settings: { settings: {
config: { from_secret: 'docker_config' },
auto_tag: true, auto_tag: true,
auto_tag_suffix: arch, auto_tag_suffix: arch,
dockerfile: 'docker/Dockerfile', dockerfile: 'docker/Dockerfile',
@ -229,6 +236,7 @@ local PipelineBuildContainer(arch='amd64') = {
local PipelineNotifications = { local PipelineNotifications = {
kind: 'pipeline', kind: 'pipeline',
image_pull_secrets: ['docker_config'],
name: 'notifications', name: 'notifications',
platform: { platform: {
os: 'linux', os: 'linux',

View File

@ -17,6 +17,9 @@ steps:
environment: environment:
PY_COLORS: 1 PY_COLORS: 1
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -97,6 +100,9 @@ steps:
depends_on: depends_on:
- clone - clone
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -125,6 +131,9 @@ steps:
environment: environment:
PY_COLORS: 1 PY_COLORS: 1
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -181,6 +190,9 @@ steps:
ref: ref:
- refs/tags/** - refs/tags/**
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -207,7 +219,7 @@ steps:
- name: dryrun - name: dryrun
pull: always pull: always
image: plugins/docker:18-linux-amd64 image: plugins/docker:19
settings: settings:
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
dry_run: true dry_run: true
@ -223,10 +235,12 @@ steps:
- build - build
- name: publish-dockerhub - name: publish-dockerhub
image: plugins/docker:18-linux-amd64 image: plugins/docker:19
settings: settings:
auto_tag: true auto_tag: true
auto_tag_suffix: amd64 auto_tag_suffix: amd64
config:
from_secret: docker_config
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
password: password:
from_secret: docker_password from_secret: docker_password
@ -241,10 +255,12 @@ steps:
- dryrun - dryrun
- name: publish-quay - name: publish-quay
image: plugins/docker:18-linux-amd64 image: plugins/docker:19
settings: settings:
auto_tag: true auto_tag: true
auto_tag_suffix: amd64 auto_tag_suffix: amd64
config:
from_secret: docker_config
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
password: password:
from_secret: quay_password from_secret: quay_password
@ -259,6 +275,9 @@ steps:
depends_on: depends_on:
- dryrun - dryrun
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -285,7 +304,7 @@ steps:
- name: dryrun - name: dryrun
pull: always pull: always
image: plugins/docker:18-linux-arm64 image: plugins/docker:19
settings: settings:
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
dry_run: true dry_run: true
@ -301,10 +320,12 @@ steps:
- build - build
- name: publish-dockerhub - name: publish-dockerhub
image: plugins/docker:18-linux-arm64 image: plugins/docker:19
settings: settings:
auto_tag: true auto_tag: true
auto_tag_suffix: arm64 auto_tag_suffix: arm64
config:
from_secret: docker_config
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
password: password:
from_secret: docker_password from_secret: docker_password
@ -319,10 +340,12 @@ steps:
- dryrun - dryrun
- name: publish-quay - name: publish-quay
image: plugins/docker:18-linux-arm64 image: plugins/docker:19
settings: settings:
auto_tag: true auto_tag: true
auto_tag_suffix: arm64 auto_tag_suffix: arm64
config:
from_secret: docker_config
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
password: password:
from_secret: quay_password from_secret: quay_password
@ -337,6 +360,9 @@ steps:
depends_on: depends_on:
- dryrun - dryrun
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -363,7 +389,7 @@ steps:
- name: dryrun - name: dryrun
pull: always pull: always
image: plugins/docker:18-linux-arm image: plugins/docker:19
settings: settings:
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
dry_run: true dry_run: true
@ -379,10 +405,12 @@ steps:
- build - build
- name: publish-dockerhub - name: publish-dockerhub
image: plugins/docker:18-linux-arm image: plugins/docker:19
settings: settings:
auto_tag: true auto_tag: true
auto_tag_suffix: arm auto_tag_suffix: arm
config:
from_secret: docker_config
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
password: password:
from_secret: docker_password from_secret: docker_password
@ -397,10 +425,12 @@ steps:
- dryrun - dryrun
- name: publish-quay - name: publish-quay
image: plugins/docker:18-linux-arm image: plugins/docker:19
settings: settings:
auto_tag: true auto_tag: true
auto_tag_suffix: arm auto_tag_suffix: arm
config:
from_secret: docker_config
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
password: password:
from_secret: quay_password from_secret: quay_password
@ -415,6 +445,9 @@ steps:
depends_on: depends_on:
- dryrun - dryrun
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -503,6 +536,9 @@ steps:
- success - success
- failure - failure
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -519,6 +555,6 @@ depends_on:
--- ---
kind: signature kind: signature
hmac: df44919980e20290304c17643e6b0f68a89a55e78c47d2bc401e697b59e2ce0d hmac: 40231bb97e628b0d1b3bc75425ce214b28c0c5bcba2b72c0d49c18e2a0d222a5
... ...