+++ This bug was initially created as a clone of Bug #1945597 +++ Setting an empty default value for `ARG` entries eliminates the need of the following downstream modifications: ``` - action: replace match: 'ARG KERNEL_VERSION' replacement: '' - action: replace match: 'ARG RT_KERNEL_VERSION' replacement: '' - action: replace match: 'ARG RHEL_VERSION' replacement: '' ``` https://github.com/openshift/ocp-build-data/blob/6861686494e12d5cbecde7d67f5ba01f4afe6323/images/driver-toolkit.yml#L10-L20 Using this bash's parameter expansion `${VAR:+-}` appends a `-` only if `$VAR` is not empty, eliminating the following downstream modifications: ``` - action: replace match: '-${KERNEL_VERSION}' replacement: '' - action: replace match: '-${RT_KERNEL_VERSION}' replacement: '' ``` https://github.com/openshift/ocp-build-data/blob/6861686494e12d5cbecde7d67f5ba01f4afe6323/images/driver-toolkit.yml#L22-L28 --- This way, ART builds will use basically the same `Dockerfile` as upstream, and we'd use those replacement modifications only when we want to explicitly pin a version: ``` content: source: modifications: - action: replace match: "ARG KERNEL_VERSION=''" replacement: "ARG KERNEL_VERSION='1.2.3'" - action: replace match: "ARG RT_KERNEL_VERSION=''" replacement: "ARG RT_KERNEL_VERSION='1.2.3'" ```
This was fixed two weeks ago and we have successful builds with this change. Moving to verified.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (Moderate: OpenShift Container Platform 4.8.2 bug fix and security update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2021:2438