Add support for AddHost in quadlet .pod and .container

Signed-off-by: Jerome degroote <jeromedu59230@gmx.fr>
This commit is contained in:
Jerome Degroote
2024-08-22 14:22:46 +02:00
parent d55b12f70b
commit 7c5d8bec0d
5 changed files with 44 additions and 0 deletions

View File

@ -257,6 +257,7 @@ Valid options for `[Container]` are listed below:
|--------------------------------------|------------------------------------------------------|
| AddCapability=CAP | --cap-add CAP |
| AddDevice=/dev/foo | --device /dev/foo |
| AddHost=hostname:192.168.10.11 | --add-host=hostname:192.168.10.11 |
| Annotation="XYZ" | --annotation "XYZ" |
| AutoUpdate=registry | --label "io.containers.autoupdate=registry" |
| CgroupsMode=no-conmon | --cgroups=no-conmon |
@ -356,6 +357,14 @@ only if it exists on the host.
This key can be listed multiple times.
### `AddHost=`
Add host-to-IP mapping to /etc/hosts.
The format is `hostname:ip`.
Equivalent to the Podman `--add-host` option.
This key can be listed multiple times.
### `Annotation=`
Set one or more OCI annotations on the container. The format is a list of `key=value` items,
@ -877,6 +886,7 @@ Valid options for `[Pod]` are listed below:
| **[Pod] options** | **podman container create equivalent** |
|-------------------------------------|----------------------------------------|
| AddHost=hostname:192.168.10.11 | --add-host=hostname:192.168.10.11 |
| ContainersConfModule=/etc/nvd\.conf | --module=/etc/nvd\.conf |
| GIDMap=0:10000:10 | --gidmap=0:10000:10 |
| GlobalArgs=--log-level=debug | --log-level=debug |
@ -896,6 +906,14 @@ Valid options for `[Pod]` are listed below:
Supported keys in the `[Pod]` section are:
### `AddHost=`
Add host-to-IP mapping to /etc/hosts.
The format is `hostname:ip`.
Equivalent to the Podman `--add-host` option.
This key can be listed multiple times.
### `ContainersConfModule=`
Load the specified containers.conf(5) module. Equivalent to the Podman `--module` option.