Repository navigation
Releases
Releases · benmoussa-younes/container
Container v0.3.3
Added
podman: the README records the cgroup delegation limit. Debian's
user@.servicedeclaresDelegate=pids memory cpu, so the account's user
manager seescpu memory pidsand a rootless unit cannot set--cpuset-cpus
or an io limit; a site that needs them declares the host-scopeDelegate=
override. The gate fails when the record loses the default or the override.
Fixed
account: the two static-range proof plays take the other identifier from the
host's first free one. On a host that runs the product, the site'scontainer
account holds 1500, so the holder check refused the gid before the range check
and the gate turned red.podman: the proof play keeps its user namespace drop-in inside its own
directory.include_varssets the role defaults as host facts, so the
remove-if-undeclared plays ignored their play variable and tried to unlink the
host's root-owned/etc/sysctl.d/62-podman-userns.conf.
Container v0.3.2
Fixed
podman: the subordinate ID plan handedawk -fthe role's own path, which
exists on the controller and not on the target; a site that converges a host
over SSH got an empty answer andThe plan carries one known answerfailed
with nothing to read. The program is now carried to the target on stdin, and a
failed invocation prints the command's status, stdout and stderr.
Added
podman: adesktopfixture (the human account and the agent hold the blocks
at 100000 and 165536, the container account holds none) proves the plan names
the third block, and the gate refuses a plan task that names a path of the
controller.
Container v0.3.1
Added
podman:podman_registry_blocksdeclares[[registry]]entries for the
account'sregistries.conf: alocation(required),insecure,blocked
andmirrors. Until now the role wrote only the search list, so a host that
declared a mirror or an insecure registry in/etc/containerslost it when
the account's complete file replaced the host-wide one. The argument spec
refuses a block without a location, and the gate renders the three shapes
from the template.
Container v0.3.0
Added
podman: the subordinate ID ranges are planned before they are written, by
roles/podman/files/subid-plan.awk. The plan refuses a range another account
holds, a range shorter thanpodman_subuid_count, a range in one file only,
two ranges in one file, and a host that delegatessubidto an NSS provider;
it adds the first free block at or afterpodman_subuid_startwhen the account
has none, and it never overwrites. A candidate must also avoid every UID and
GID that/etc/passwdand/etc/groupdeclare, and the count is capped at
1 048 576. A host whose accounts or subordinate ranges come from an NSS
provider is refused, because the plan reads the files.podman:podman_subuid_repair(false by default) is the one repair the role
accepts: it removes this account's unusable ranges, then adds the block the
plan names.podman:podman_system_migraterunspodman system migrateas the owning
account after a change, and the kernel's/proc/self/uid_mapandgid_mapare
read back and asserted against the planned block.podman: the host's base is asserted before anything is written (Debian 13
read from/etc/debian_version, systemd, cgroup v2). The edition brands
/etc/os-release, soansible_distribution_versionreads the edition's own
1.0and is not used.podman:catatonitis installed. The Quadlet defaultRunInit=trueneeds it
and Debian lists it as a Recommends ofpodman, so a host that installs no
recommends started no container.- gate: the planner is proven against twenty fixture host cases, including a
host UID inside the candidate block and a malformed line, and
tests/playbooks/subid.ymlruns the role's own decision tasks and its four
refusals without root, in ten plays;tests/inventories/sandbox/converges
the collection on the test host with its configuration relocated under
/var/tmp. - gate: every defect line carries at most ten lines of a failed command's output.
- gate and CI:
scripts check --deny-warnings,--modulefor the modules, and
scripts run --no-warningsfor the gate. account: the collection creates the login account the rootless engine runs
as, so a host needs no pre-existing human. The defaults arecontainerwith
uid/gid 1500, the distribution's home for that name and/bin/bash; the name,
UID, GID, home and shell are inventory values. The role refuses to rewrite an existing
identity (an account or a group that already holds another UID or GID fails
the run), reads the account back, and checks that the home belongs to it.
playbooks/site.ymlruns it first, when the engine or the declarations are
enabled.quadlet: a declared unit and the drop-ins the role writes for it are
0600, not0644: the text belongs to the account, and a credential left in
it is readable by that account only.quadlet: the boot contract reads the[Install]section itself: a
WantedBy=/RequiredBy=/DefaultInstance=written in another section no
longer satisfies it.quadlet: a declaration carriesdropins, a list of{name, content}files
written into<name>.<type>.d/. The role refuses a name that does not end in
.conf, a name the product owns, a duplicate and a drop-in on an absent unit,
keeps the list it wrote in.ansible-managed.json, and removes a drop-in the
site stops declaring (or withdraws with its unit). Quadlet merges each
declared.confinto the generated unit without naming it there, so the
sandbox asserts the drop-in's effect. The argument/sandbox keys stay refused
in a drop-in too.quadlet:PodmanArgs,GlobalArgs,Unmask,SeccompProfileand
Privilegedare refused in any declared unit, whatever their value, because
they bypass the hardening drop-in rather than relax one setting. The
published host-port floor is enforced. APublishPortwhose
host port is belowquadlet_unprivileged_port_start(the host's
net.ipv4.ip_unprivileged_port_startwhen empty) fails the run, and template
unit names (foo@.container) are accepted. A template that carries[Install]
must also carryDefaultInstance=, or no instance is activated.podman:podman_auto_update(false by default) enables the account's
podman-auto-update.timer, without which a unit'sAutoUpdate=registryis a
dead setting. The engine read-back now refuses avfsstore, a cgroup other
than v2 and a network backend other than netavark, instead of reading only the
rootless flag.
Fixed
- a subordinate range that another account also held was accepted in silence,
whileroles/podman/defaults/main.ymlandSECURITY.mdclaimed a collision
was a hard failure; usermodwas called with the same hard-coded 100000 block for every account,
so two engines on one host collided;- nothing read back the mapping the kernel installed, so a file the engine
ignored passed the run; release.scscomputed its program name in a helper, which raised
SCRIPTS-LINT-0004; each call site now passes a literalrun_request.
Changed
SECURITY.mdstates the mechanisms that actually isolate a container (no LSM
confines a rootless container on Debian 13) and the risk of the socket the
role enables.podman:container_host_editionnow acceptsworkstationas well as
server. A workstation installs the same rootless engine and the same
hardening for the dedicated account; a site that develops on it relaxes the
defaults it needs (podman_read_only,quadlet_image_digest_required, ...)
through the role's variables, so the edition stays a declared label and not a
second profile.- The base image moves to
debian:13-slim@sha256:8aa5a7bf…(Debian 13.8, the
OpenSSL 3.5.7→3.5.9 security delta), pinsaptto the base's own
snapshot.debian.orgdate, purges the volatile apt/dpkg logs and archives the
dpkg-querypackage set in the image. With--timestamp, two--no-cache
builds of one commit produce the same digest (measured);images/base/REFRESHED
dates the snapshot and the gate refuses a base older than 30 days. quadlet:AddCapabilityis bounded byquadlet_permitted_capabilities
(CAP_NET_BIND_SERVICEby default) and checked in a unit and its drop-ins:
the hardening drop-in drops every capability, and only a named one can come
back.CAP_SYS_ADMINand the other administration capabilities fail the run.podman: the README states what the enabled user socket grants (the
account's engine rights) and that rootless Podman on Debian applies no
AppArmor or SELinux layer (podman info:apparmorEnabled=false,
selinuxEnabled=false); seccomp is the confinement.podman: the Debian 13 / systemd / cgroup v2 guard sits inside the
podman_enabledblock: a disabled role now only removes its own drop-in, and
the argument spec resolves before the account is read (podman_homehas an
empty default, likequadlet_home).podman: the engine's configuration moved into the account's home
(~/.config/containers/{containers,registries}.conf,policy.json), owned
by the account and read before the host-wide files; forregistries.confand
policy.jsonthe user file replaces the host-wide one, so the account's
registry list is complete. The role removes the host-wide
99-container-podman.confit wrote before and the99-podman.confof the
retired edition roles, and never writes/etc/containersagain.podman:no_new_privilegesis removed fromcontainers.confand the
podman_no_new_privilegesvariable is gone: Podman 5.4.2 accepts the key and
never applies it (measured:NoNewPrivsstays 0 with the key in either
table and turns 1 with--security-opt no-new-privileges). The Quadlet
hardening drop-in still setsNoNewPrivileges=truefor the product's units.podman:containers.confstates the product's choices: a read-only root
(podman_read_only), the distribution's seccomp profile
(podman_seccomp_profile), the caller's user namespace (podman_userns),
the nofile ulimit (podman_default_ulimits),pull_policy, and thepasta
rootless network command.podman:registries.confsetsshort-name-mode = "enforcing"
(podman_short_name_mode), and the newpolicy.jsonaccepts only the
registriespodman_registriesdeclares.quadlet: a declaredImage=ending in.imagemust resolve at role run
time to a declaredtype: imageunit or to a<stem>.imagefile in the
generator directory; an undeclared or path-shaped reference fails the run
instead of writing a unit the generator refuses.quadlet: a declared.containeror.imagemust name its image by digest
(@sha256:and 64 hex characters), or reference a.imageunit by name
(base.image, whose ownImage=is checked), while
quadlet_image_digest_requiredis on;image_digest: falseis the per-unit
opt-out..kubeand.buildunits are not parsed. The rule reads a unit's
dropinstoo, and the port floor does as well: a value written beside the
unit cannot bypass either check.- The supported
ansible-corerange is 2.20 to below 2.23: 2.19 reaches
end of life on 2026-11-30, and the CI matrix no longer runs it. - The base image locks every setuid/setgid bit after it creates the account
and locks root, so a bit introduced by the account setup cannot survive. podman_userdefaults to the accountroles/accountdeclares
(account_name,containerby default) instead of the undefined
accounts_human.name, which left the engine with an empty account on any
host that did not define that foreign variable.- The README no longer asks for an existing human account, and the sandbox
inventory no longer asks the owner to create its account by hand.
Migration
- From
0.2.0: nothing to do by hand on a host the role manages. The role
moves the engine's configuration into the account's home and removes...
Container v0.2.0
Added
podman:container_host_editionstates the edition the host already
carries. The collection owns no identity: the argument spec acceptsserver
only and an unsupported value fails validation; applying the role without the
declaration fails its first task, whether or not the engine is selected.podman: the role removes the99-podman.confthe retiredserverand
workstationroles wrote underregistries.conf.dandcontainers.conf.d,
before writing its own99-container-podman.conf, so exactly one file owns
each configuration.podman_stale_config_filesfollows the two directories,
and the removal restarts the user socket like any other engine change.quadlet:quadlet_default_memoryandquadlet_default_cpu_quotagive every
container unit aMemoryMax=and aCPUQuota=unless it declares its own.
The role writes a per-unit drop-in only while the unit omits the key (a
Quadlet drop-in wins over the unit file), and removes it as soon as the unit
declares the key or the default is emptied.- The gate's
one registries writercheck: onlyroles/podman/defaults/main.yml
may name a registries drop-in, and the retired name survives only as the
removal target.
Changed
- The base image keeps Debian's own
/etc/os-releaseand no longer writes a
PRETTY_NAME, a version of its own or/etc/container-edition: the
collection is a capability and owns no identity, in an image or on a host. - The collection version is
0.2.0. The invariants a0.3.0would carry —
images pinned by digest,storage.conf.d, the auto-update timer, a service
account, no TCP socket — are not implemented yet, so this release does not
claim them.
Fixed
podman:--checkno longer fails on a host where the user-namespace
drop-in is not applied yet. The read runs in check mode (it only reads) and
the assert is skipped there, because check mode cannot apply the sysctl it
asserts. Measured before:ok=8 changed=1 failed=1, "is , not 1".
Migration
- From
0.1.0: declarecontainer_host_edition: serverin the host's
variables. The engine role now refuses to run without it, whether or not
podman_enabledis true, andserveris the only accepted value. - A host that ran an edition's engine keeps no configuration of its own: the
retired99-podman.confis removed on the first run, and the product's
99-container-podman.confreplaces it.
Container v0.1.0
Added
- The Ansible collection
benmoussa.containerand its 0.1.0 release. - The rootless Podman engine role: packages, registry search path, engine
drop-in, user socket, linger and subordinate IDs. It never creates a
container. - The Quadlet role: the site's unit files, a user-manager reload and a
read-back of every generated unit. It ships no container definition. - The base image
images/base/Containerfile: the Debian minimal base pinned by
digest, TLS roots,tzdata,curl,procps, the Scripts interpreter (0.1.2,
verified against its releaseSHA256SUMS), one non-root account, a locked
root, no setuid bit and a branded/etc/os-release. - The engine's defaults in
containers.conf:no_new_privilegeson, the pids
limit and the log size bounded,umask0077 and thecrunruntime — Debian
leaves all of them permissive. - The Quadlet role writes the product's global hardening drop-in
(NoNewPrivileges, all capabilities dropped, read-only rootfs,RunInit,
pids and ulimit bounds, journald logs) and refuses a container unit that
declaresNetwork=host,User=0,NoNewPrivileges=false,
ReadOnly=falseorSecurityLabelDisable=truewhile it is on. - The example inventory with documentation values only (TEST-NET-1).
- The repository gate, the CI workflow and the release workflow.
Security
- The engine is rootless only; the rootful socket is not enabled.
- No registry credential, secret or site definition is part of the product.
- The configuration drop-ins are named
99-container-podman.conf, so the
collection does not collide with a site's own Podman configuration.