1801 Commits

Author SHA1 Message Date
80c0fceb24 Add support for --userns=nomap
From a security point of view, it would be nice to be able to map a
rootless usernamespace that does not use your own UID within the
container.

This would add protection against a hostile process escapping the
container and reading content in your homedir.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-04-21 15:29:04 -04:00
cb09c26c65 Merge pull request #13505 from rst0git/checkpoint-image-1
Add support for checkpoint image
2022-04-21 11:58:56 -04:00
df156ab787 [CI:DOCS] podman build --pull=*missing*
Document the *missing* pull policy in `podman build`.

Fixes: #13864
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2022-04-21 14:37:02 +02:00
756ecd5400 Add support for checkpoint image
This is an enhancement proposal for the checkpoint / restore feature of
Podman that enables container migration across multiple systems with
standard image distribution infrastructure.

A new option `--create-image <image>` has been added to the
`podman container checkpoint` command. This option tells Podman to
create a container image.  This is a standard image with a single layer,
tar archive, that that contains all checkpoint files. This is similar to
the current approach with checkpoint `--export`/`--import`.

This image can be pushed to a container registry and pulled on a
different system.  It can also be exported locally with `podman image
save` and inspected with `podman inspect`. Inspecting the image would
display additional information about the host and the versions of
Podman, criu, crun/runc, kernel, etc.

`podman container restore` has also been extended to support image
name or ID as input.

Suggested-by: Adrian Reber <areber@redhat.com>
Signed-off-by: Radostin Stoyanov <radostin@redhat.com>
2022-04-20 18:55:39 +01:00
80d1752791 slirp4netns: actually make ipv6 default
We already have ipv6 enabled as default via the containers.conf setting.
However the documentation did not reflect this. Also if no options were
set in contianers.conf it would have ipv6 disabled.

We can now remove the extra option from containers.conf.

Also fix another outdated option description for host.containers.internal
and add that the options can also be set in contianers.conf.

[NO NEW TESTS NEEDED]

Fixes #13914

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-04-20 13:59:01 +02:00
bc8d8737b7 Merge pull request #13921 from rhatdan/rename
Add missing events to podman-events man page
2022-04-19 19:46:18 -04:00
9d2ad5b839 Merge pull request #13890 from fulminemizzega/main
[CI:DOCS] Fix selinux docs for kubernetes yaml
2022-04-19 16:37:00 -04:00
a2077e5eae Add missing events to podman-events man page
[NO NEW TESTS NEEDED]

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-04-19 16:30:26 -04:00
cc4bc25bd0 Merge pull request #13898 from baude/machinelistquiet
Add --quiet to machine ls
2022-04-18 10:27:16 -04:00
8d3075e332 Merge pull request #13583 from rhatdan/ipc
Add support for ipc namespace modes "none, private, sharable"
2022-04-16 12:30:01 -04:00
99bcd65959 Add --quiet to machine ls
The podman machine ls command would benefit from a --quiet flag which
would only print the machine names without the extra information.  It
also implies --noheader as well.  This can be helpful for scripting with
the podman cli.

Signed-off-by: Brent Baude <bbaude@redhat.com>

[NO NEW TESTS NEEDED]

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-04-16 08:54:56 -05:00
e716790af9 Fix typo in generate kube docs for selinux labeling
Signed-off-by: Federico Rizzo <fulminemizzega@users.noreply.github.com>
2022-04-15 21:51:30 +00:00
08d08f995e Correct play kube docs for selinux labeling
Signed-off-by: Federico Rizzo <fulminemizzega@users.noreply.github.com>
2022-04-15 21:51:30 +00:00
25eeaec219 Merge pull request #13849 from baude/defaultvolumess
Mount $HOME:$HOME by default in podman machine init
2022-04-15 06:10:17 -04:00
f2ab79cc02 Merge pull request #13868 from cdoern/cloneSwap
Fix Memory Swappiness passing in Container Clone
2022-04-15 05:54:05 -04:00
6076e1a9a5 Merge pull request #13616 from giuseppe/passwd-entry
run, create: add --passwd-entry
2022-04-14 15:35:20 -04:00
900739d134 Add container.conf default volume to init
containers.conf now has a default volumes field for podman machine.
this pr inserts those values as the default volumes in init.

Signed-off-by: Brent Baude <bbaude@redhat.com>

[NO NEW TESTS NEEDED]

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-04-14 13:06:05 -05:00
f38b03d375 Fix Memory Swappiness passing in Container Clone
`DefineCreateFlags` was excluding clone from using the memory-swappiness flag leading the value to be zero
when our deafult is -1. Rearrange the if/else to give clone these memory related options

resolves #13856

Signed-off-by: cdoern <cdoern@redhat.com>
2022-04-14 10:40:29 -04:00
001f619eab Merge pull request #13872 from vrothberg/revert-size
Revert "images --size"
2022-04-14 07:18:52 -04:00
3f2939c2ef run, create: add --passwd-entry
It allows to customize the entry that is written to the `/etc/passwd`
file when --passwd is used.

Closes: https://github.com/containers/podman/issues/13185

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2022-04-14 11:22:13 +02:00
97f93dc78e Revert "images --size"
This reverts commit e133a06d2f4a3e94bfbd60b647046f2f515c9c24.

@nalind found a proper fix in c/storage [1] to address the performance
issue.  So we really don't need the flag anymore.  Note the flag has
never made it into any release.

[1] d76b3606fc

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2022-04-14 10:58:36 +02:00
b962fb9f29 Merge pull request #13853 from chuanchang/fix_typo_in_podman_container_clone_docs
[CI:DOCS] fix typo in podman-container-clone.1.md
2022-04-13 12:22:52 -04:00
78b6dcd31c Merge pull request #13829 from baude/machineinspect
Introduce machine inspect
2022-04-13 11:05:22 -04:00
6c878b7a53 docs: fix typo in podman-container-clone.1.md
Signed-off-by: Alex Jia <chuanchang.jia@gmail.com>
2022-04-13 19:16:09 +08:00
8710197e85 Introduce machine inspect
Allow users to inspect their podman virtual machines. This will be
helpful for debug and development alike, because more details about the
machine can be collected.

Signed-off-by: Brent Baude <bbaude@redhat.com>

[NO NEW TESTS NEEDED]

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-04-12 15:51:39 -05:00
3987c529f4 Add support for ipc namespace modes "none, private, sharable"
Fixes: #13265

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-04-12 13:35:51 -04:00
fb4fc03ec4 Pretty print systemd services file
Fixes: #13337

I added newline only on options IE Begin with "-"

[NO NEW TESTS NEEDED]

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-04-12 06:02:48 -04:00
0ebd2882f4 Merge pull request #13821 from eriksjolund/fix_userns_auto_docs
[CI:DOCS] Rewrite rootless --userns=auto docs
2022-04-12 05:50:43 -04:00
923d454b2f [CI:DOCS] Rewrite rootless --userns=auto docs
* Remove the statement that rootless --userns=auto does not work.

* Mention that --userns=keep-id consumes all subuids and subgids.

Co-authored-by: Tom Sweeney <tsweeney@redhat.com>

Signed-off-by: Erik Sjölund <erik.sjolund@gmail.com>
2022-04-12 08:24:04 +03:00
784a13f577 network create: add support for ipam-driver none
Add a new flag to set the ipam-driver. Also adds a new ipam driver none
mode which only creates interfaces but does not assign addresses.

Fixes #13521

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-04-11 11:09:15 +02:00
cdbc33112e Merge pull request #13687 from rhatdan/VENDOR
Vendor in new opencontainers/selinux
2022-04-08 10:42:44 -04:00
dc17195bd9 Vendor in new opencontainers/selinux
Also update vendor of containers/common,buildah,storage,image

Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2069586

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-04-08 09:02:52 -04:00
e133a06d2f images --size
Add a --size option to podman images to allow for disabling computing
the size of listed images.  If listing images is critical to
performance, user may chose to turn off size computation to speed things
up.

Context: #13755
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2022-04-08 10:09:38 +02:00
e73547a635 Unify examples section across several man pages: pod rm/start/unpause
Signed-off-by: Patrycja Guzik <patrycja.k.guzik@gmail.com>
2022-04-05 23:40:07 +02:00
dd9eec06a3 Unify examples section across several man pages: init/kill
Signed-off-by: Patrycja Guzik <patrycja.k.guzik@gmail.com>
2022-04-04 22:46:28 +02:00
c185d8c0d6 Add option for pod logs to display different colors per container.
Signed-off-by: Krzysztof Baran <krysbaran@gmail.com>
Signed-off-by: gcalin <caling@protonmail.com>
2022-03-29 17:29:13 +02:00
a8e6c639e2 Unify examples section across several man pages
This commit adjusts example sections across several man pages
to the format seen in other pages.

Signed-off-by: Patrycja Guzik <patrycja.k.guzik@gmail.com>
2022-03-28 21:56:13 +02:00
7df6849f16 Merge pull request #13648 from adamaze/main
[CI:DOCS] clarifying "loginctl enable-linger" section in doc
2022-03-28 09:08:00 -04:00
463c0b9f2d Merge pull request #13607 from rvandernoort/filter_docs
[CI:DOCS]: Update docs for image filters
2022-03-27 13:17:31 +02:00
ab41037c87 Update filter docs with missing entries and add negation option.
[NO NEW TESTS NEEDED]

Signed-off-by: rvandernoort <s.r.vandernoort@student.tudelft.nl>
2022-03-27 12:59:22 +02:00
c01d1f8e37 [CI:DOCS] docs: drop note about upcoming RHEL 7.7
it was released more than two years ago.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2022-03-25 11:08:52 +01:00
e657c7a170 Merge pull request #13622 from rhatdan/systemd1
When running systemd in a container set container_uuid
2022-03-24 19:05:44 +01:00
caaaf07c1e Merge pull request #13587 from giuseppe/clone-to-pod
container: allow clone to an existing pod
2022-03-24 18:09:43 +01:00
d4bf6b4d78 clarifying "loginctl enable-linger" section in doc
Signed-off-by: Adam Maryniuk <adamaze@gmail.com>
2022-03-24 12:33:05 -04:00
b469bf5c05 container: allow clone to an existing pod
Closes: https://github.com/containers/podman/issues/3979

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2022-03-24 14:24:50 +01:00
7189b6f269 podman machine set: clarify --rootful option
It is not quite clear what the difference between `podman machine set
--rootful` and `podman system connection default` is.
Add a small note with the difference, the --rootful option will also
affect the socket forwarding.

Fixes #13515

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-03-24 12:24:52 +01:00
9b0c8d23bd man pages: sort flags, and keep them that way
Command flags (OPTIONS) in man pages have to date been in
haphazard order. Sometimes that order is sensible, e.g.,
most-important options first, but more often they're
just in arbitrary places. This makes life hard for users.

Here, I update the man-page-check Makefile script so it
checks and enforces alphabetical order in OPTIONS sections.
Then -- the hard part -- update all existing man pages to
conform to this requirement.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-03-23 13:49:42 -06:00
5e28cbc5fc When running systemd in a container set container_uuid
systemd expects the container_uuid environment variable be set
when it is running in a container.

Fixes: https://github.com/containers/podman/issues/13187

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-03-23 15:05:30 -04:00
a8743d3327 Merge pull request #13588 from flouthoc/import-os-arch
import: allow users to set `--os`, `--arch` and `--variant` of image imports
2022-03-23 13:15:47 +01:00
eedce31eb4 import: allow users to set os, arch and variant of imports
Allows users to set `--os` , `--arch` and `--variant` of the image
created from the custom import.

Following is useful when user is already aware of the values which are
correct for their generated rootfs

Signed-off-by: Aditya R <arajan@redhat.com>
2022-03-23 11:22:55 +05:30