automation-tests/pkg/specgen
Matt Heon 458ba5a8af Fix `podman stop` and `podman run --rmi`
This started off as an attempt to make `podman stop` on a
container started with `--rm` actually remove the container,
instead of just cleaning it up and waiting for the cleanup
process to finish the removal.

In the process, I realized that `podman run --rmi` was rather
broken. It was only done as part of the Podman CLI, not the
cleanup process (meaning it only worked with attached containers)
and the way it was wired meant that I was fairly confident that
it wouldn't work if I did a `podman stop` on an attached
container run with `--rmi`. I rewired it to use the same
mechanism that `podman run --rm` uses, so it should be a lot more
durable now, and I also wired it into `podman inspect` so you can
tell that a container will remove its image.

Tests have been added for the changes to `podman run --rmi`. No
tests for `stop` on a `run --rm` container as that would be racy.

Fixes #22852
Fixes RHEL-39513

Signed-off-by: Matt Heon <mheon@redhat.com>
2024-08-20 09:51:18 -04:00
..
generate Fix `podman stop` and `podman run --rmi` 2024-08-20 09:51:18 -04:00
container_validate.go Replace golang.org/x/exp/slices with slices from std 2024-04-23 11:16:40 +02:00
namespaces.go Replace golang.org/x/exp/slices with slices from std 2024-04-23 11:16:40 +02:00
namespaces_test.go drop support for "pasta" as a network name 2024-02-05 13:57:24 +01:00
pod_validate.go Bump Go module to v5 2024-02-08 09:35:39 -05:00
podspecgen.go Add --restart flag to pod create 2023-05-02 10:29:58 -04:00
resources_freebsd.go specgen/generate: Factor out setting resource limits from CompleteSpec 2022-09-08 08:24:18 +01:00
resources_linux.go specgen/generate: Factor out setting resource limits from CompleteSpec 2022-09-08 08:24:18 +01:00
specgen.go Fix `podman stop` and `podman run --rmi` 2024-08-20 09:51:18 -04:00
specgen_local.go chore: delete obsolete // +build lines 2024-01-04 11:53:38 +02:00
specgen_remote.go chore: delete obsolete // +build lines 2024-01-04 11:53:38 +02:00
specgen_test.go Convert SpecGen values to be nullable where possible 2024-01-30 10:42:24 -05:00
utils.go chore: delete obsolete // +build lines 2024-01-04 11:53:38 +02:00
utils_linux.go chore: delete obsolete // +build lines 2024-01-04 11:53:38 +02:00
volumes.go Add support for image volume subpaths 2024-04-25 14:12:27 -04:00
winpath.go pkg: switch to golang native error wrapping 2022-07-08 08:54:47 +02:00
winpath_linux.go pkg/specgen: use fileutils.(Le|E)xists 2024-04-19 09:52:14 +02:00
winpath_unsupported.go chore: delete obsolete // +build lines 2024-01-04 11:53:38 +02:00
winpath_windows.go pkg/specgen: use fileutils.(Le|E)xists 2024-04-19 09:52:14 +02:00