diff --git a/pipeline.json b/pipeline.json new file mode 100644 index 00000000..e69de29b diff --git a/pipelines/concourse.yml b/pipelines/concourse.yml index e9fd4c65..e994df0e 100644 --- a/pipelines/concourse.yml +++ b/pipelines/concourse.yml @@ -510,9 +510,8 @@ jobs: - get: prometheus-chart tags: [k8s-topgun] params: {untar: true} - - get: postgresql-chart + - get: postgresql-chart-git tags: [k8s-topgun] - params: {untar: true} - get: ci tags: [k8s-topgun] - task: k8s-topgun @@ -1737,14 +1736,12 @@ resources: - name: prometheus-community url: https://prometheus-community.github.io/helm-charts -- name: postgresql-chart - type: helm-chart - icon: *helm-icon +# Using the git instead of helm-chart resource because Bitnami charts are hosted on Docker Hub and we sometimes run into their rate limits +- name: postgresql-chart-git + type: git source: - chart: bitnami/postgresql - repos: - - name: bitnami - url: https://charts.bitnami.com/bitnami + uri: "https://github.com/bitnami/charts.git" + tag_filter: postgresql/((postgresql-chart-version)) - name: golang-linux type: s3 diff --git a/pipelines/helm-prs.yml b/pipelines/helm-prs.yml index 22f9165e..ba5f25e6 100644 --- a/pipelines/helm-prs.yml +++ b/pipelines/helm-prs.yml @@ -4,6 +4,10 @@ resource_types: type: registry-image source: {repository: loggregatorbot/github-pr-resource} +- name: helm-chart + type: registry-image + source: {repository: linkyard/helm-chart-resource, tag: 2.17.0} + resources: - name: chart-pr type: pull-request @@ -13,13 +17,6 @@ resources: base_branch: ((branch)) access_token: ((pr_access_token)) -- name: helm-charts - type: git - icon: github - source: - uri: https://github.com/helm/charts.git - branch: master - - name: concourse type: git icon: github @@ -34,11 +31,11 @@ resources: uri: https://github.com/concourse/ci.git branch: master -- name: concourse-image +- name: concourse-dev-image type: registry-image icon: docker source: - repository: concourse/concourse + repository: concourse/concourse-dev tag: ((concourse_image_tag)) username: ((docker.username)) password: ((docker.password)) @@ -51,6 +48,22 @@ resources: username: ((docker.username)) password: ((docker.password)) +# Using the git instead of helm-chart resource because Bitnami charts are hosted on Docker Hub and we sometimes run into their rate limits +- name: postgresql-chart-git + type: git + source: + uri: https://github.com/bitnami/charts.git + tag_filter: postgresql/((postgresql-chart-version)) + +- name: prometheus-chart + type: helm-chart + icon: ship-wheel + source: + chart: prometheus-community/prometheus + repos: + - name: prometheus-community + url: https://prometheus-community.github.io/helm-charts + jobs: - name: k8s-topgun serial: true @@ -69,16 +82,19 @@ jobs: - in_parallel: - get: chart-pr tags: [k8s-topgun] - - get: helm-charts - tags: [k8s-topgun] - get: concourse tags: [k8s-topgun] - - get: concourse-image + - get: concourse-dev-image tags: [k8s-topgun] - get: ci tags: [k8s-topgun] - get: unit-image tags: [k8s-topgun] + - get: prometheus-chart + tags: [k8s-topgun] + params: { untar: true } + - get: postgresql-chart-git + tags: [ k8s-topgun ] - put: chart-pr inputs: [chart-pr] params: {path: chart-pr, status: pending, context: k8s-topgun} @@ -89,7 +105,7 @@ jobs: file: ci/tasks/k8s-topgun.yml input_mapping: concourse-chart: chart-pr - concourse-rc-image: concourse-image + concourse-rc-image: concourse-dev-image image: unit-image params: IN_CLUSTER: "true" diff --git a/pipelines/reconfigure.yml b/pipelines/reconfigure.yml index 420a6647..a3c181db 100644 --- a/pipelines/reconfigure.yml +++ b/pipelines/reconfigure.yml @@ -266,6 +266,8 @@ jobs: - in_parallel: - set_pipeline: concourse file: pipelines-and-tasks/pipelines/concourse.yml + vars: + postgresql-chart-version: 16.3.2 - set_pipeline: helm-chart file: pipelines-and-tasks/pipelines/helm-chart.yml instance_vars: @@ -280,6 +282,7 @@ jobs: concourse_base_branch: master concourse_image_name: concourse/concourse concourse_image_tag: latest + postgresql-chart-version: 16.3.2 - set_pipeline: helm-prs file: pipelines-and-tasks/pipelines/helm-prs.yml instance_vars: @@ -288,6 +291,7 @@ jobs: concourse_base_branch: master concourse_image_name: concourse/concourse-rc concourse_image_tag: latest + postgresql-chart-version: 16.3.2 - set_pipeline: docs-prs team: contributor file: docs-ci/ci/prs-pipeline.yml diff --git a/tasks/k8s-topgun.yml b/tasks/k8s-topgun.yml index 8cdf2418..733959ed 100644 --- a/tasks/k8s-topgun.yml +++ b/tasks/k8s-topgun.yml @@ -11,7 +11,7 @@ inputs: - name: concourse-rc-image - name: concourse-chart - name: prometheus-chart -- name: postgresql-chart +- name: postgresql-chart-git caches: - path: gopath diff --git a/tasks/scripts/k8s-topgun b/tasks/scripts/k8s-topgun index 5fc94f88..5ae05088 100755 --- a/tasks/scripts/k8s-topgun +++ b/tasks/scripts/k8s-topgun @@ -15,7 +15,11 @@ gke_auth mkdir -p helm-charts/stable cp -r prometheus-chart/prometheus helm-charts/stable -cp -r postgresql-chart/postgresql helm-charts/stable +cp -r postgresql-chart-git/bitnami/postgresql helm-charts/stable + +pushd helm-charts/stable/postgresql +helm dependency build +popd export CONCOURSE_IMAGE_DIGEST="$(cat concourse-rc-image/digest)" export CONCOURSE_IMAGE_TAG="$(cat concourse-rc-image/tag)"