Hi all,
I am trying to evaluate Nomad for my use case - so far it seems to be pretty close to what I need. I have a test cluster with three nodes using Fedora 35 + podman + btrfs + crun + nomad-driver-podman up and running. I am able to submit a job to the Nomad cluster, see its ports, stop it, scale it, and so on. I have the following questions:
-
How can I make Nomad run containers in an unprivileged user namespace, as in
podman --userns=auto? So far the top-level process of thedocker.io/library/redis:latestcontainer runs assystemd-oom(UID 999), as seen withps axufrom the host OS. When I runpodman run --userns=auto -it docker.io/library/redis:latestmanually, the UID of the toplevel process respects the UID range from/etc/subuid. -
Does logging to Nomad work with podman driver? When I run
nomad alloc logs d2f3035a, I get an empty output, even though the allocation ID seems to be valid. -
I have problem adding podman-specific configuration to my
nomad.hcland the job description files. I use the documentation from here: Drivers: podman | Nomad by HashiCorp - when I for example add the top-level sectionplugin "nomad-driver-podman" { }to thenomad.hclconfig, as described in the first example of the “Plugin Options” section in that page, nomad fails with:
nomad[30862]: ==> Error starting agent: failed to create plugin loader: failed to initialize plugin loader: parsing plugin configurations failed: 1 error occurred:
nomad[30862]: * plugin "podman" (driver): failed to parse config: Invalid label: No argument or block type is named "disable_log_collection".
nomad[30862]: 2022-03-18T13:25:50.450+0100 [ERROR] agent: error starting agent:
nomad[30862]: error=
nomad[30862]: | failed to create plugin loader: failed to initialize plugin loader: parsing plugin configurations failed: 1 error occurred:
nomad[30862]: | * plugin "podman" (driver): failed to parse config: Invalid label: No argument or block type is named "disable_log_collection".
nomad[30862]: |
The similar thing happens when I add logging = { driver = "nomad" } section inside the task config { } section. When trying to run the job, I get the following error message:
Invalid label: No argument or block type is named "logging".
Thanks in advance for any hints.
-Yenya