[v10.1.x] ImagePullSecrets: Add GAR secret to image_pull_secret in .drone.yml (#80917)
`ImagePullSecrets`: Add `GAR` secret to `image_pull_secret` in `.drone.yml` (#80912)
* Add GAR secret to image_pull_secret
* Fix starlark fmt
(cherry picked from commit 65104a7efa)
This commit is contained in:
+88
-42
@@ -5,7 +5,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: pr-verify-drone
|
||||
node:
|
||||
@@ -55,7 +56,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: pr-verify-starlark
|
||||
node:
|
||||
@@ -105,7 +107,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: pr-test-frontend
|
||||
node:
|
||||
@@ -184,7 +187,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: pr-lint-frontend
|
||||
node:
|
||||
@@ -273,7 +277,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: pr-test-backend
|
||||
node:
|
||||
@@ -379,7 +384,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: pr-lint-backend
|
||||
node:
|
||||
@@ -469,7 +475,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: pr-build-e2e
|
||||
node:
|
||||
@@ -751,7 +758,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: pr-integration-tests
|
||||
node:
|
||||
@@ -1016,7 +1024,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: pr-docs
|
||||
node:
|
||||
@@ -1090,7 +1099,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: pr-shellcheck
|
||||
node:
|
||||
@@ -1134,7 +1144,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: pr-integration-benchmarks
|
||||
node:
|
||||
@@ -1310,7 +1321,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: main-docs
|
||||
node:
|
||||
@@ -1385,7 +1397,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: main-test-frontend
|
||||
node:
|
||||
@@ -1442,7 +1455,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: main-lint-frontend
|
||||
node:
|
||||
@@ -1509,7 +1523,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: main-test-backend
|
||||
node:
|
||||
@@ -1588,7 +1603,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: main-lint-backend
|
||||
node:
|
||||
@@ -1657,7 +1673,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: main-build-e2e-publish
|
||||
node:
|
||||
@@ -2057,7 +2074,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: main-integration-tests
|
||||
node:
|
||||
@@ -2301,7 +2319,8 @@ depends_on:
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: main-windows
|
||||
platform:
|
||||
@@ -2345,7 +2364,8 @@ depends_on:
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: main-trigger-downstream
|
||||
node:
|
||||
@@ -2428,7 +2448,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: publish-docker-public
|
||||
node:
|
||||
@@ -2534,7 +2555,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: publish-artifacts-public
|
||||
node:
|
||||
@@ -2603,7 +2625,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: publish-npm-packages-public
|
||||
node:
|
||||
@@ -2668,7 +2691,8 @@ depends_on:
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: publish-packages
|
||||
node:
|
||||
@@ -2756,7 +2780,8 @@ depends_on:
|
||||
- main-test-backend
|
||||
- main-test-frontend
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: rgm-main-prerelease
|
||||
node:
|
||||
@@ -2831,7 +2856,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: release-whatsnew-checker
|
||||
node:
|
||||
@@ -2875,7 +2901,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: release-test-frontend
|
||||
node:
|
||||
@@ -2930,7 +2957,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: release-test-backend
|
||||
node:
|
||||
@@ -3007,7 +3035,8 @@ depends_on:
|
||||
- release-test-backend
|
||||
- release-test-frontend
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: rgm-tag-prerelease
|
||||
node:
|
||||
@@ -3078,7 +3107,8 @@ clone:
|
||||
depends_on:
|
||||
- rgm-tag-prerelease
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: rgm-tag-prerelease-windows
|
||||
platform:
|
||||
@@ -3142,7 +3172,8 @@ depends_on:
|
||||
- rgm-tag-prerelease
|
||||
- rgm-tag-prerelease-windows
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: rgm-tag-verify-prerelease-assets
|
||||
node:
|
||||
@@ -3187,7 +3218,8 @@ depends_on:
|
||||
- release-test-backend
|
||||
- release-test-frontend
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: rgm-version-branch-prerelease
|
||||
node:
|
||||
@@ -3252,7 +3284,8 @@ clone:
|
||||
depends_on:
|
||||
- rgm-version-branch-prerelease
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: rgm-prerelease-verify-prerelease-assets
|
||||
node:
|
||||
@@ -3291,7 +3324,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: nightly-test-frontend
|
||||
node:
|
||||
@@ -3344,7 +3378,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: nightly-test-backend
|
||||
node:
|
||||
@@ -3419,7 +3454,8 @@ depends_on:
|
||||
- nightly-test-backend
|
||||
- nightly-test-frontend
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: rgm-nightly-build
|
||||
node:
|
||||
@@ -3526,7 +3562,8 @@ clone:
|
||||
depends_on:
|
||||
- rgm-nightly-build
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: rgm-nightly-publish
|
||||
node:
|
||||
@@ -3675,7 +3712,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: testing-test-backend-windows
|
||||
platform:
|
||||
@@ -3727,7 +3765,8 @@ depends_on: []
|
||||
environment:
|
||||
EDITION: oss
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: integration-tests
|
||||
node:
|
||||
@@ -3951,7 +3990,8 @@ clone:
|
||||
disable: true
|
||||
depends_on: []
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
- gcr
|
||||
- gar
|
||||
kind: pipeline
|
||||
name: publish-ci-windows-test-image
|
||||
platform:
|
||||
@@ -4390,7 +4430,13 @@ get:
|
||||
name: .dockerconfigjson
|
||||
path: secret/data/common/gcr
|
||||
kind: secret
|
||||
name: dockerconfigjson
|
||||
name: gcr
|
||||
---
|
||||
get:
|
||||
name: .dockerconfigjson
|
||||
path: secret/data/common/gar
|
||||
kind: secret
|
||||
name: gar
|
||||
---
|
||||
get:
|
||||
name: pat
|
||||
@@ -4561,6 +4607,6 @@ kind: secret
|
||||
name: gcr_credentials
|
||||
---
|
||||
kind: signature
|
||||
hmac: 319eafee68d3b78d2674b05ac1a341ef098a9a1cf2b28736debc0011fe120e84
|
||||
hmac: 461cb43aa119901524e6fbd522c3230e6bf7c44ebe6686119f7899e1a06657cc
|
||||
|
||||
...
|
||||
|
||||
@@ -6,7 +6,11 @@ load(
|
||||
"scripts/drone/steps/lib.star",
|
||||
"slack_step",
|
||||
)
|
||||
load("scripts/drone/vault.star", "pull_secret")
|
||||
load(
|
||||
"scripts/drone/vault.star",
|
||||
"gar_pull_secret",
|
||||
"gcr_pull_secret",
|
||||
)
|
||||
|
||||
failure_template = "Build {{build.number}} failed for commit: <https://github.com/{{repo.owner}}/{{repo.name}}/commit/{{build.commit}}|{{ truncate build.commit 8 }}>: {{build.link}}\nBranch: <https://github.com/{{ repo.owner }}/{{ repo.name }}/commits/{{ build.branch }}|{{ build.branch }}>\nAuthor: {{build.author}}"
|
||||
|
||||
@@ -83,7 +87,7 @@ def pipeline(
|
||||
},
|
||||
],
|
||||
"depends_on": depends_on,
|
||||
"image_pull_secrets": [pull_secret],
|
||||
"image_pull_secrets": [gcr_pull_secret, gar_pull_secret],
|
||||
}
|
||||
if environment:
|
||||
pipeline.update(
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
"""
|
||||
This module returns functions for generating Drone secrets fetched from Vault.
|
||||
"""
|
||||
pull_secret = "dockerconfigjson"
|
||||
gcr_pull_secret = "gcr"
|
||||
gar_pull_secret = "gar"
|
||||
drone_token = "drone_token"
|
||||
prerelease_bucket = "prerelease_bucket"
|
||||
gcp_upload_artifacts_key = "gcp_upload_artifacts_key"
|
||||
@@ -43,7 +44,8 @@ def secrets():
|
||||
vault_secret(gcp_grafanauploads, "infra/data/ci/grafana-release-eng/grafanauploads", "credentials.json"),
|
||||
vault_secret(gcp_grafanauploads_base64, "infra/data/ci/grafana-release-eng/grafanauploads", "credentials_base64"),
|
||||
vault_secret("grafana_api_key", "infra/data/ci/grafana-release-eng/grafanacom", "api_key"),
|
||||
vault_secret(pull_secret, "secret/data/common/gcr", ".dockerconfigjson"),
|
||||
vault_secret(gcr_pull_secret, "secret/data/common/gcr", ".dockerconfigjson"),
|
||||
vault_secret(gar_pull_secret, "secret/data/common/gar", ".dockerconfigjson"),
|
||||
vault_secret("github_token", "infra/data/ci/github/grafanabot", "pat"),
|
||||
vault_secret(drone_token, "infra/data/ci/drone", "machine-user-token"),
|
||||
vault_secret(prerelease_bucket, "infra/data/ci/grafana/prerelease", "bucket"),
|
||||
|
||||
Reference in New Issue
Block a user