spiegel_podman/libpod/define
Matthew Heon 06b5a8c2f7 Print errors from individual containers in pods
The infra/abi code for pods was written in a flawed way, assuming
that the map[string]error containing individual container errors
was only set when the global error for the pod function was nil;
that is not accurate, and we are actually *guaranteed* to set the
global error when any individual container errors. Thus, we'd
never actually include individual container errors, because the
infra code assumed that err being set meant everything failed and
no container operations were attempted.

We were originally setting the cause of the error to something
nonsensical ("container already exists"), so I made a new error
indicating that some containers in the pod failed. We can then
ignore that error when building the report on the pod operation
and actually return errors from individual containers.

Unfortunately, this exposed another weakness of the infra code,
which was discarding the container IDs. Errors from individual
containers are not guaranteed to identify which container they
came from, hence the use of map[string]error in the Pod API
functions. Rather than restructuring the structs we return from
pkg/infra, I just wrapped the returned errors with a message
including the ID of the container.

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-07-06 13:10:13 -04:00
..
annotations.go add {generate,play} kube 2020-05-06 17:08:22 +02:00
config.go Do not share container log driver for exec 2020-06-17 11:11:46 -04:00
container_inspect.go move go module to v2 2020-07-06 15:52:17 +02:00
containerstate.go v2 podman stats 2020-05-05 08:46:51 -05:00
ctr_inspect.go Add basic structure of output for APIv2 pod inspect 2020-04-15 17:21:00 -04:00
errors.go Print errors from individual containers in pods 2020-07-06 13:10:13 -04:00
exec_codes.go Revert "Exec: use ErrorConmonRead" 2020-03-09 09:50:40 -04:00
healthchecks.go Fix remote integration for healthchecks 2020-05-20 14:43:01 -05:00
info.go Turn on More linters 2020-06-15 07:05:56 -04:00
pod_inspect.go pod config: add a CreateCommand field 2020-06-11 11:01:13 +02:00
podstate.go APIv2 review corrections #3 2020-01-25 15:09:09 -06:00
runtime.go Add support for containers.conf 2020-03-27 14:36:03 -04:00
version.go move go module to v2 2020-07-06 15:52:17 +02:00