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

Sync build-definitions #69

Merged
merged 1 commit into from
Feb 6, 2025
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
2 changes: 1 addition & 1 deletion pac/tasks/acs-deploy-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ spec:
fi

- name: report
image: registry.access.redhat.com/ubi8-minimal@sha256:7583ca0ea52001562bd81a961da3f75222209e6192e4e413ee226cff97dbd48c
image: registry.access.redhat.com/ubi8-minimal@sha256:d16d4445b1567f29449fba3b6d2bc37db467dc3067d33e940477e55aecdf6e8e
volumeMounts:
- name: repository
mountPath: /workspace/repository
Expand Down
4 changes: 2 additions & 2 deletions pac/tasks/acs-image-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ spec:
oc annotate taskrun $(context.taskRun.name) task.output.location=logs

- name: rox-image-check
image: registry.access.redhat.com/ubi8-minimal@sha256:7583ca0ea52001562bd81a961da3f75222209e6192e4e413ee226cff97dbd48c
image: registry.access.redhat.com/ubi8-minimal@sha256:d16d4445b1567f29449fba3b6d2bc37db467dc3067d33e940477e55aecdf6e8e
volumeMounts:
- name: rox-secret
mountPath: /rox-secret
Expand Down Expand Up @@ -121,7 +121,7 @@ spec:
cp roxctl_image_check_output.json /steps-shared-folder/acs-image-check.json

- name: report
image: registry.access.redhat.com/ubi8-minimal@sha256:7583ca0ea52001562bd81a961da3f75222209e6192e4e413ee226cff97dbd48c
image: registry.access.redhat.com/ubi8-minimal@sha256:d16d4445b1567f29449fba3b6d2bc37db467dc3067d33e940477e55aecdf6e8e
volumeMounts:
- name: shared-folder
mountPath: /steps-shared-folder
Expand Down
4 changes: 2 additions & 2 deletions pac/tasks/acs-image-scan.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ spec:
oc annotate taskrun $(context.taskRun.name) task.output.location=logs

- name: rox-image-scan
image: registry.access.redhat.com/ubi8-minimal@sha256:7583ca0ea52001562bd81a961da3f75222209e6192e4e413ee226cff97dbd48c
image: registry.access.redhat.com/ubi8-minimal@sha256:d16d4445b1567f29449fba3b6d2bc37db467dc3067d33e940477e55aecdf6e8e
volumeMounts:
- name: rox-secret
mountPath: /rox-secret
Expand Down Expand Up @@ -171,7 +171,7 @@ spec:
set_test_output_result SUCCESS "$note"

- name: report
image: registry.access.redhat.com/ubi8-minimal@sha256:7583ca0ea52001562bd81a961da3f75222209e6192e4e413ee226cff97dbd48c
image: registry.access.redhat.com/ubi8-minimal@sha256:d16d4445b1567f29449fba3b6d2bc37db467dc3067d33e940477e55aecdf6e8e
volumeMounts:
- name: shared-folder
mountPath: /steps-shared-folder
Expand Down
11 changes: 9 additions & 2 deletions pac/tasks/buildah-rhtap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ spec:
value: $(params.BUILD_ARGS_FILE)
steps:
- name: build
image: registry.access.redhat.com/ubi9/buildah@sha256:c62b2318eb4709c216ad25969abae5ff6b56e9879d266b539a46fdfc99e8361e
image: registry.access.redhat.com/ubi9/buildah@sha256:27d837f9bc69ad3c3651cf3315e2501b137c11baa553d9d46140e5cf7fa7873a
args:
- $(params.BUILD_ARGS[*])
script: |
Expand Down Expand Up @@ -103,6 +103,13 @@ spec:
--digestfile /tmp/files/image-digest $IMAGE \
docker://$IMAGE

# Push the image to a unique tag to avoid race conditions
buildah push \
--tls-verify="$TLSVERIFY" \
--retry=5 \
--digestfile /tmp/files/image-digest "$IMAGE" \
"docker://${IMAGE%:*}:$(context.taskRun.name)"

# Set task results
buildah images --format '{{ .Name }}:{{ .Tag }}@{{ .Digest }}' | grep -v $IMAGE > $(results.BASE_IMAGES_DIGESTS.path)
cat /tmp/files/image-digest | tee $(results.IMAGE_DIGEST.path)
Expand Down Expand Up @@ -137,7 +144,7 @@ spec:
name: tmpfiles

- name: merge-sboms
image: registry.access.redhat.com/ubi8/python-311@sha256:ec2f4c89e18373c75a72f5b47da4d3ee826e8961a9c6a26ba2fd3112f5a41e4a
image: registry.access.redhat.com/ubi8/python-311@sha256:552046341bbe2e4a0e89be4401403ccd39293ea53a736db2e5ec695bc6d906aa
env:
- name: RESULT_PATH
value: $(results.SBOM_BLOB_URL.path)
Expand Down
4 changes: 2 additions & 2 deletions pac/tasks/init.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ spec:

steps:
- name: init
image: registry.access.redhat.com/ubi9/skopeo:9.4-14.1728984400@sha256:891ee232a9319ed0f675c318f9605422bde7436328e7faec7dc896a206a78e54
image: registry.access.redhat.com/ubi9/skopeo:9.5-1737537999@sha256:b28469b997a6f7ef996859e8d4f4bd25b964084fc2caac23a9c01b8a53adb1d7
env:
- name: IMAGE_URL
value: $(params.image-url)
Expand All @@ -41,7 +41,7 @@ spec:
echo "Determine if Image Already Exists"
# Build the image when rebuild is set to true or image does not exist
# The image check comes last to avoid unnecessary, slow API calls
if [ "$REBUILD" == "true" ] || [ "$SKIP_CHECKS" == "false" ] || ! skopeo inspect --raw docker://$IMAGE_URL &>/dev/null; then
if [ "$REBUILD" == "true" ] || [ "$SKIP_CHECKS" == "false" ] || ! skopeo inspect --no-tags --raw "docker://$IMAGE_URL" &>/dev/null; then
echo -n "true" > $(results.build.path)
else
echo -n "false" > $(results.build.path)
Expand Down