Merge pull request #27256 from givensuman/T-27065-add-quadlet-build-args-support

Add BuildArg key to quadlets
This commit is contained in:
openshift-merge-bot[bot]
2025-10-16 15:24:52 +00:00
committed by GitHub
4 changed files with 30 additions and 1 deletions

View File

@@ -1715,6 +1715,7 @@ Valid options for `[Build]` are listed below:
| Annotation=annotation=value | --annotation=annotation=value |
| Arch=aarch64 | --arch=aarch64 |
| AuthFile=/etc/registry/auth\.json | --authfile=/etc/registry/auth\.json |
| BuildArg=foo=bar | --build-arg foo=bar |
| ContainersConfModule=/etc/nvd\.conf | --module=/etc/nvd\.conf |
| DNS=192.168.55.1 | --dns=192.168.55.1 |
| DNSOption=ndots:1 | --dns-option=ndots:1 |
@@ -1757,6 +1758,14 @@ Path of the authentication file.
This is equivalent to the `--authfile` option of `podman build`.
### `BuildArg=`
Specifies a build argument and its value in the same way environment variables are
(e.g., env=*value*), but it is not added to the environment variable list in the
resulting image's configuration. Can be listed multiple times.
This is equivalent to the `--build-arg` option of `podman build`.
### `ContainersConfModule=`
Load the specified containers.conf(5) module. Equivalent to the Podman `--module` option.
@@ -2281,7 +2290,7 @@ Yaml=/opt/k8s/deployment.yml
WantedBy=multi-user.target default.target
```
Example for locally built image to be used in a container:
Example for locally built image to be used in a container with build-specific arguments:
`test.build`
```
@@ -2293,6 +2302,9 @@ ImageTag=localhost/imagename
# expecting to find a Containerfile/Dockerfile
# + other files needed to build the image
SetWorkingDirectory=unit
# Set build arguments VERSION and DEBUG
BuildArg=VERSION=1.0 \
DEBUG=false
```
`test.container`