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

chore(updatecli): restore ubi9 manifest (RedHat Container Registry's json file is now valid) #901

Merged
merged 10 commits into from
Oct 31, 2024
Prev Previous commit
Next Next commit
fix(updatecli): Added comments
  • Loading branch information
gounthar committed Sep 26, 2024
commit 6f800cf76387bccb7e8fa3e84ff48f99f25de2c3
28 changes: 15 additions & 13 deletions updatecli/updatecli.d/rhel-ubi9.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
---
# This YAML configuration file is used to bump the UBI9 version in the Dockerfile and docker-bake.hcl and create a pull request with the changes.

name: Bump UBI9 version

scms:
Expand All @@ -15,49 +17,49 @@ scms:

sources:
latestVersion:
name: "Get the latest UBI9 Linux version"
name: "Get the latest UBI9 Linux version" # Source to get the latest UBI9 version
kind: shell
spec:
command: bash updatecli/scripts/ubi9-latest-tag.sh
command: bash updatecli/scripts/ubi9-latest-tag.sh # Command to fetch the latest UBI9 tag

conditions:
checkUbi9DockerImage:
kind: dockerimage
name: Check if the container image "ubi9" is available
name: Check if the container image "ubi9" is available # Condition to check if the UBI9 Docker image is available
spec:
architectures:
- linux/amd64
- linux/arm64
- linux/s390x
- linux/ppc64le
image: registry.access.redhat.com/ubi9
image: registry.access.redhat.com/ubi9 # Docker image to check. The tag is automatically set to the version found in the only source

targets:
updateDockerfile:
name: "Update the value of the base image (ARG UBI9_TAG) in the Dockerfile"
name: "Update the value of the base image (ARG UBI9_TAG) in the Dockerfile" # Target to update the Dockerfile with the new UBI9 tag
kind: dockerfile
sourceid: latestVersion
spec:
file: rhel/ubi9/Dockerfile
file: rhel/ubi9/Dockerfile # Path to the Dockerfile
instruction:
keyword: "ARG"
matcher: "UBI9_TAG"
keyword: "ARG" # Dockerfile instruction keyword
matcher: "UBI9_TAG" # Dockerfile instruction matcher
scmid: default
updateDockerBake:
name: "Update the default value of the variable UBI9_TAG in the docker-bake.hcl"
name: "Update the default value of the variable UBI9_TAG in the docker-bake.hcl" # Target to update the docker-bake.hcl file with the new UBI9 tag
kind: hcl
sourceid: latestVersion
spec:
file: docker-bake.hcl
path: variable.UBI9_TAG.default
file: docker-bake.hcl # Path to the docker-bake.hcl file
path: variable.UBI9_TAG.default # Path to the variable in the HCL file
scmid: default

actions:
default:
kind: github/pullrequest
scmid: default
title: Bump UBI9 version to {{ source "latestVersion" }}
title: Bump UBI9 version to {{ source "latestVersion" }} # Title of the pull request
spec:
labels:
- dependencies
- rhel-ubi9
- rhel-ubi9 # Labels for the pull request