add dockerhub auth for ci

This commit is contained in:
Robert Kaussow 2020-11-27 12:09:33 +01:00
parent 885f11fa8a
commit 282e21ef2f
No known key found for this signature in database
GPG Key ID: 65362AE74AF98B61
2 changed files with 56 additions and 1 deletions

View File

@ -16,6 +16,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',
@ -42,6 +43,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',
@ -64,6 +66,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',
@ -93,6 +96,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',
@ -151,6 +155,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',
@ -168,6 +173,7 @@ local PipelineBuildContainer(arch='amd64') = {
name: 'dryrun', name: 'dryrun',
image: 'plugins/docker:18-linux-' + arch, image: 'plugins/docker:18-linux-' + arch,
settings: { settings: {
config: { from_secret: 'docker_config' },
dry_run: true, dry_run: true,
dockerfile: 'docker/Dockerfile', dockerfile: 'docker/Dockerfile',
repo: 'thegeeklab/${DRONE_REPO_NAME}', repo: 'thegeeklab/${DRONE_REPO_NAME}',
@ -183,6 +189,7 @@ local PipelineBuildContainer(arch='amd64') = {
name: 'publish-dockerhub', name: 'publish-dockerhub',
image: 'plugins/docker:18-linux-' + arch, image: 'plugins/docker:18-linux-' + arch,
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',
@ -199,6 +206,7 @@ local PipelineBuildContainer(arch='amd64') = {
name: 'publish-quay', name: 'publish-quay',
image: 'plugins/docker:18-linux-' + arch, image: 'plugins/docker:18-linux-' + arch,
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',
@ -223,6 +231,7 @@ local PipelineBuildContainer(arch='amd64') = {
local PipelineDocs = { local PipelineDocs = {
kind: 'pipeline', kind: 'pipeline',
image_pull_secrets: ['docker_config'],
name: 'docs', name: 'docs',
platform: { platform: {
os: 'linux', os: 'linux',
@ -331,6 +340,7 @@ local PipelineDocs = {
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

@ -16,6 +16,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
@ -86,6 +89,9 @@ steps:
depends_on: depends_on:
- clone - clone
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -113,6 +119,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
@ -169,6 +178,9 @@ steps:
ref: ref:
- refs/tags/** - refs/tags/**
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -195,6 +207,8 @@ steps:
- name: dryrun - name: dryrun
image: plugins/docker:18-linux-amd64 image: plugins/docker:18-linux-amd64
settings: settings:
config:
from_secret: docker_config
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
dry_run: true dry_run: true
password: password:
@ -213,6 +227,8 @@ steps:
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
@ -231,6 +247,8 @@ steps:
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
@ -245,6 +263,9 @@ steps:
depends_on: depends_on:
- dryrun - dryrun
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -271,6 +292,8 @@ steps:
- name: dryrun - name: dryrun
image: plugins/docker:18-linux-arm64 image: plugins/docker:18-linux-arm64
settings: settings:
config:
from_secret: docker_config
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
dry_run: true dry_run: true
password: password:
@ -289,6 +312,8 @@ steps:
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
@ -307,6 +332,8 @@ steps:
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
@ -321,6 +348,9 @@ steps:
depends_on: depends_on:
- dryrun - dryrun
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -347,6 +377,8 @@ steps:
- name: dryrun - name: dryrun
image: plugins/docker:18-linux-arm image: plugins/docker:18-linux-arm
settings: settings:
config:
from_secret: docker_config
dockerfile: docker/Dockerfile dockerfile: docker/Dockerfile
dry_run: true dry_run: true
password: password:
@ -365,6 +397,8 @@ steps:
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
@ -383,6 +417,8 @@ steps:
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
@ -397,6 +433,9 @@ steps:
depends_on: depends_on:
- dryrun - dryrun
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -486,6 +525,9 @@ steps:
- refs/heads/master - refs/heads/master
- refs/tags/** - refs/tags/**
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -579,6 +621,9 @@ steps:
- success - success
- failure - failure
image_pull_secrets:
- docker_config
trigger: trigger:
ref: ref:
- refs/heads/master - refs/heads/master
@ -592,6 +637,6 @@ depends_on:
--- ---
kind: signature kind: signature
hmac: e633e5064224d4db579e4592dea0ca83a1b601f2dbcecb07ec8064b5cdb39e78 hmac: 8f057b4d2d6c2ea3bf6e683aa43b869e09334340343fe006c373b8c7f69c98ae
... ...