summaryrefslogtreecommitdiff
path: root/libpod
Commit message (Collapse)AuthorAge
* Handle podman exec capabilities correctlyDaniel J Walsh2021-01-07
| | | | Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Merge pull request #8805 from giuseppe/single-user-mapped-rootOpenShift Merge Robot2021-01-06
|\ | | | | libpod: handle single user mapped as root
| * libpod: handle single user mapped as rootGiuseppe Scrivano2020-12-24
| | | | | | | | | | | | | | | | | | | | | | if a single user is mapped in the user namespace, handle it as root. It is needed for running unprivileged containers with a single user available without being forced to run with euid and egid set to 0. Needs: https://github.com/containers/storage/pull/794 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* | Merge pull request #8892 from mheon/fix_8886OpenShift Merge Robot2021-01-06
|\ \ | | | | | | Ensure that user-specified HOSTNAME is honored
| * | Ensure that user-specified HOSTNAME is honoredMatthew Heon2021-01-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When adding the HOSTNAME environment variable, only do so if it is not already present in the spec. If it is already present, it was likely added by the user, and we should honor their requested value. Fixes #8886 Signed-off-by: Matthew Heon <mheon@redhat.com>
* | | Merge pull request #8685 from mheon/ignore_containersconf_sysctls_shared_netOpenShift Merge Robot2021-01-05
|\ \ \ | | | | | | | | Ignore containers.conf sysctls when sharing namespaces
| * | | Add default sysctls for pod infra containersMatthew Heon2021-01-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ensure that infra containers for pods will grab default sysctls from containers.conf, to match how other containers are created. This mostly affects the other containers in the pod, which will inherit those sysctls when they join the pod's namespaces. Signed-off-by: Matthew Heon <mheon@redhat.com>
* | | | Merge pull request #8831 from bblenard/issue-8658-system-prune-reclaimed-spaceOpenShift Merge Robot2021-01-05
|\ \ \ \ | |_|/ / |/| | | Rework pruning to report reclaimed space
| * | | Rework pruning to report reclaimed spaceBaron Lenardson2020-12-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change adds code to report the reclaimed space after a prune. Reclaimed space from volumes, images, and containers is recorded during the prune call in a PruneReport struct. These structs are collected into a slice during a system prune and processed afterwards to calculate the total reclaimed space. Closes #8658 Signed-off-by: Baron Lenardson <lenardson.baron@gmail.com>
* | | | Merge pull request #8873 from baude/issue8864OpenShift Merge Robot2021-01-05
|\ \ \ \ | | | | | | | | | | close journald when reading
| * | | | close journald when readingbaude2021-01-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | when reading from journald, we need to close the journal handler for events and logging. Fixes: #8864 Signed-off-by: baude <bbaude@redhat.com>
* | | | | Merge pull request #8878 from mheon/no_edit_configOpenShift Merge Robot2021-01-04
|\ \ \ \ \ | | | | | | | | | | | | Ensure we do not edit container config in Exec
| * | | | | Ensure we do not edit container config in ExecMatthew Heon2021-01-04
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The existing code grabs the base container's process, and then modifies it for use with the exec session. This could cause errors in `podman inspect` or similar on the container, as the definition of its OCI spec has been changed by the exec session. The change never propagates to the DB, so it's limited to a single process, but we should still avoid it when possible - so deep-copy it before use. Signed-off-by: Matthew Heon <mheon@redhat.com>
* | | | | Merge pull request #8875 from rhatdan/imageOpenShift Merge Robot2021-01-04
|\ \ \ \ \ | | | | | | | | | | | | Allow image errors to bubble up from lower level functions.
| * | | | | Allow image errors to bubble up from lower level functions.Daniel J Walsh2021-01-04
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently we ignore ErrMultipleImages being returned from findImageInRepoTags. Fixes: https://github.com/containers/podman/issues/8868 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* / / / / systemd: make rundir always accessibleGiuseppe Scrivano2021-01-04
|/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | so that the PIDFile can be accessed also without being in the rootless user namespace. Closes: https://github.com/containers/podman/issues/8506 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* | | | Merge pull request #8823 from giuseppe/exec-honor-privilegedOpenShift Merge Robot2021-01-04
|\ \ \ \ | |/ / / |/| | | exec: honor --privileged
| * | | exec: honor --privilegedGiuseppe Scrivano2020-12-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | write the capabilities to the configuration passed to the OCI runtime. Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
| * | | libpod: change function to accept ExecOptionsGiuseppe Scrivano2020-12-24
| | |/ | |/| | | | | | | Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* | | Merge pull request #8852 from afbjorklund/slirp_sandbox-no_pivot_rootOpenShift Merge Robot2020-12-30
|\ \ \ | | | | | | | | The slirp4netns sandbox requires pivot_root
| * | | The slirp4netns sandbox requires pivot_rootAnders F Björklund2020-12-29
| |/ / | | | | | | | | | | | | | | | Disable the sandbox, when running on rootfs Signed-off-by: Anders F Björklund <anders.f.bjorklund@gmail.com>
* | | Merge pull request #8853 from jubalh/gentooOpenShift Merge Robot2020-12-30
|\ \ \ | | | | | | | | Add support for Gentoo file to package query
| * | | Add support for Gentoo file to package queryMichael Vetter2020-12-29
| |/ / | | | | | | | | | | | | | | | | | | | | | On Gentoo systems where `app-portage/gentoolkit` is installed the binary `equery` is used to query for information on which package a file belongs to. Signed-off-by: Michael Vetter <jubalh@iodoru.org>
* / / Consolidate filter logic to pkg subdirectoryBaron Lenardson2020-12-24
|/ / | | | | | | | | | | | | Per the conversation on pull/8724 I am consolidating filter logic and helper functions under the pkg/domain/filters dir. Signed-off-by: Baron Lenardson <lenardson.baron@gmail.com>
* | Merge pull request #8822 from baude/issue8733OpenShift Merge Robot2020-12-24
|\ \ | | | | | | re-open container log files
| * | re-open container log filesbaude2020-12-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | when following container log files, if the file gets rotated due to something like size limit, re-open it and keep following. Fixes: #8733 Signed-off-by: baude <bbaude@redhat.com>
* | | Merge pull request #8806 from rhatdan/keyringOpenShift Merge Robot2020-12-23
|\ \ \ | | | | | | | | Pass down EnableKeyring from containers.conf to conmon
| * | | Pass down EnableKeyring from containers.conf to conmonDaniel J Walsh2020-12-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We have a new field in containers.conf that tells whether or not we want to generate a new keyring in a container. This field was being ignored. It now will be followed and passed down to conmon. Fixes: https://github.com/containers/podman/issues/8384 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | | | Merge pull request #8609 from rhatdan/imageOpenShift Merge Robot2020-12-23
|\ \ \ \ | |_|/ / |/| | | Prefer read/write images over read/only images
| * | | Prefer read/write images over read/only imagesDaniel J Walsh2020-12-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With additional stores there is a risk that you could have multiple images with the same name. IE An older image in a read/only store versus a newer version in the read/write store. This patch will ignore multiple images with the same name iff one is read/write and all of the others are read/only. Fixes: https://github.com/containers/podman/issues/8176 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | | | Merge pull request #8787 from jsoref/spellingOpenShift Merge Robot2020-12-23
|\ \ \ \ | | | | | | | | | | Spelling
| * | | | SpellingJosh Soref2020-12-22
| | |/ / | |/| | | | | | | | | | Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
* | | | Merge pull request #8793 from zhangguanzhang/vol-opOpenShift Merge Robot2020-12-23
|\ \ \ \ | | | | | | | | | | Fix missing options in volume's display while setting uid and gid
| * | | | Fix missing options in volumes display while setting uid and gidzhangguanzhang2020-12-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ``` $ podman volume create testvol --opt o=uid=1001,gid=1001 $ ./bin/podman volume create testvol2 --opt o=uid=1001,gid=1001 $ podman volume inspect testvol "Options": {}, $ podman volume inspect testvol2 "Options": { "GID": "1001", "UID": "1001", "o": "uid=1001,gid=1001" }, ``` Signed-off-by: zhangguanzhang <zhangguanzhang@qq.com>
* | | | | Merge pull request #8804 from baude/issue8512Daniel J Walsh2020-12-23
|\ \ \ \ \ | |_|/ / / |/| | | | add pod filter for ps
| * | | | add pod filter for psbaude2020-12-22
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | adds the ability to filter containers based on the filter "pod". the value can be a pod name or its full or partial id. Fixes: #8512 Signed-off-by: baude <bbaude@redhat.com>
* | | | Merge pull request #8724 from bblenard/support-volume-filters-in-system-pruneOpenShift Merge Robot2020-12-22
|\ \ \ \ | |_|/ / |/| | | Add volume filters to system prune
| * | | Add volume filters to system pruneBaron Lenardson2020-12-21
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change was missed in pull/8689. Now that volume pruneing supports filters system pruneing can pass its filters down to the volume pruneing. Additionally this change adds tests for the following components * podman system prune subcommand with `--volumes` & `--filter` options * apiv2 api tests for `/system/` and `/libpod/system` endpoints Relates to #8453, #8672 Signed-off-by: Baron Lenardson <lenardson.baron@gmail.com>
* / / Add Security information to podman infoDaniel J Walsh2020-12-22
|/ / | | | | | | | | | | | | | | When debugging issues, it would be helpful to know the security settings of the system running into the problem. Adding security info to `podman info` is also useful to users. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | Merge pull request #8750 from rhatdan/resetOpenShift Merge Robot2020-12-17
|\ \ | | | | | | Don't accidently remove XDG_RUNTIME_DIR when reseting storage
| * | Don't accidently remove XDG_RUNTIME_DIR when reseting storageDaniel J Walsh2020-12-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In certain cases XDG_RUNTIME_DIR was deleted by accident based on settings in the storage.conf. This patch verifies that when doing a storage reset, we don't accidently remove XDG_RUNTIME_DIR. Fixes: https://github.com/containers/podman/issues/8680 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | | Merge pull request #8756 from Luap99/fix-8748OpenShift Merge Robot2020-12-16
|\ \ \ | | | | | | | | Always add the default gateway to the cni config file
| * | | Always add the default gateway to the cni config filePaul Holzinger2020-12-16
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `podman network create` should always add a gateway to the cni config. If no gateway is given use the first ip in the subnet. CNI does not require the gateway field but we need it because of network inspect. This worked with previous version but was dropped in Commit(e7a72d72fd59). Fixes #8748 Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
* / / Add support for pacman package version queryxatier2020-12-16
|/ / | | | | | | | | | | | | | | | | | | - refactor package query logic to be package manager agnostic. - `pacman -Qo` is the equivalent to `rpm -qf` [1]. [1] https://wiki.archlinux.org/index.php/Pacman/Rosetta#Querying_specific_packages Signed-off-by: xatier <xatierlike@gmail.com>
* | Add LogSize to container inspectDaniel J Walsh2020-12-15
| | | | | | | | | | | | | | Other log options are available so we need to add ability to look up LogSize. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | libpod, conmon: change log level for rootlessGiuseppe Scrivano2020-12-15
| | | | | | | | | | | | | | | | | | Change the log level when running as rootless when moving conmon to a different cgroup. Closes: https://github.com/containers/podman/issues/8721 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* | Merge pull request #8696 from Luap99/podman-events-untilOpenShift Merge Robot2020-12-14
|\ \ | | | | | | podman events allow future time for --until
| * | podman events allow future time for --untilPaul Holzinger2020-12-11
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The podman events aren't read until the given timestamp if the timestamp is in the future. It just reads all events until now and exits afterwards. This does not make sense and does not match docker. The correct behavior is to read all events until the given time is reached. This fixes a bug where the wrong event log file path was used when running first time with a new storage location. Fixes #8694 This also fixes the events api endpoint which only exited when an error occurred. Otherwise it just hung after reading all events. Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
* | Merge pull request #8693 from giuseppe/drop-valid-id-in-userns-checkOpenShift Merge Robot2020-12-14
|\ \ | | | | | | podman: drop checking valid rootless UID
| * | podman: drop checking valid rootless UIDGiuseppe Scrivano2020-12-11
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | do not check whether the specified ID is valid in the user namespace. crun handles this case[1], so the check in Podman prevents to get to the OCI runtime at all. $ podman run --user 10:0 --uidmap 0:0:1 --rm -ti fedora:33 sh -c 'id; cat /proc/self/uid_map' uid=10(10) gid=0(root) groups=0(root),65534(nobody) 10 0 1 [1] https://github.com/containers/crun/pull/556 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>