Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build csb-docproxy image with new builder image feature #151

Merged
merged 1 commit into from
Dec 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions ci/container/internal/base_vars.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
base-image: ubuntu-hardened
base-image-tag: latest
# Some Dockerfiles may wish to specify a separate builder image for a multi-stage build. Set these vars to do so. By default, it is the same as base-image to avoid pulling additional layers.
builder-image: ubuntu-hardened
builder-image-tag: latest
oci-build-params: {}
common-pipelines-trigger: false
dockerfile-path: []
Expand Down
5 changes: 5 additions & 0 deletions ci/container/internal/csb-docproxy/vars.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
builder-image: general-task
builder-image-tag: latest
image-repository: csb-docproxy
src-repo: cloud-gov/csb
src-branch: brokerpak-topic
1 change: 1 addition & 0 deletions ci/container/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ jobs:
- legacy-domain-certificate-renewer-testing
- opensearch-testing
- opensearch-dashboards-testing
- csb-docproxy

do:
- set_pipeline: ((.:name))
Expand Down
15 changes: 9 additions & 6 deletions container/oci-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,17 @@ image_resource:
tag: latest

caches:
- path: cache
- path: cache

inputs:
- name: src
- name: base-image
- name: common-pipelines
- name: common-dockerfiles
- name: src
- name: base-image
- name: builder-image
- name: common-pipelines
- name: common-dockerfiles

outputs:
- name: image
- name: image

run:
path: build
Expand All @@ -38,3 +39,5 @@ params:
CONTEXT: src
# Load the base image tarball from the base-image input into an OCI image reference.
IMAGE_ARG_base_image: base-image/image.tar
# Load the builder image in the same manner.
IMAGE_ARG_builder_image: builder-image/image.tar
9 changes: 9 additions & 0 deletions container/pipeline-internal.yml
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,15 @@ resources:
tag: ((base-image-tag))
aws_region: us-gov-west-1

- name: builder-image
type: registry-image
source:
aws_access_key_id: ((ecr_aws_key))
aws_secret_access_key: ((ecr_aws_secret))
repository: ((builder-image))
tag: ((builder-image-tag))
aws_region: us-gov-west-1

- name: common-pipelines
type: git
source:
Expand Down