153 Commits

Author SHA1 Message Date
c46fd411e0 Merge pull request #19098 from imphil/userns-docs
[CI:DOCS] Better document the default value of --userns
2023-07-14 13:12:42 +02:00
5e64cbf358 docs: podman run --network mention comma separted names
This syntax was used prior to 4.0 and is still supported for backwards
compatibility.

Fixes #19089

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-07-13 16:28:01 +02:00
cce8501a5b [CI:DOCS] Reformat and reorder table with --userns options
Reorder the table with --userns options to match the description below.
Also, reformat the Markdown to be better readable in source form.

Signed-off-by: Philipp Wagner <phw@ibm.com>
2023-07-12 16:05:06 +02:00
a69194b02f manifest inspect: support authentication
Previous tests have worked by pure chance since the client and server
ran on the same host; the server picked up the credentials created by
the client login.

Extend the gating tests and add a new integration test which is further
capable of exercising the remote code.

Note that fixing authentication support requires adding a new
`--authfile` CLi flag to `manifest inspect`.  This will at least allow
for passing an authfile to be bindings.  Username and password are not
yet supported.

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-07-10 16:26:19 +02:00
eec438222a [CI:DOCS] uidmap man pages: fix corrupt italics
The markdown-to-manpage sequence interprets
_from_uid_ and *from_uid* differently.
Use the latter syntax to get the expected result.

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

Signed-off-by: Erik Sjölund <erik.sjolund@gmail.com>
2023-07-09 10:50:48 +02:00
d874790bc6 auto update: fix usage of --authfile
The --authfile flag has been ignored.  Fix that and add a test to make
sure we won't regress another time.  Requires a new --tls-verify flag
to actually test the code.

Also bump c/common since common/pull/1538 is required to correctly check
for updates.  Note that I had to use the go-mod-edit-replace trick on
c/common as c/buildah would otherwise be moved back to 1.30.

Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2218315
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-07-05 08:30:39 +02:00
5aabc5088a [CI:DOCS] Better document the default value of --userns
Better document which value `podman run --userns` has if no default
value is specified. Also improve documentation of "host" being an alias
for "".

Fixes #15764

Signed-off-by: Philipp Wagner <phw@ibm.com>
2023-07-03 17:31:39 +02:00
4a5396b467 [CI:DOCS] uidmap man pages: fix corrupt tables
The markdown-to-manpage sequence needs a long row of dashes,
not a single dash. A single dash, as used in this one option,
generates unreadable *roff.

Also, some tool somewhere doesn't like too-long columns. Shrtn thm.

Also, verify that there are no more three-or-fewer-dash columns:

    $ ack '\|\s+-{1,3}\s' docs/source/markdown

Fixes: #19086

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-07-02 17:38:42 -06:00
bd69b151fa run,create: modify --env-merge behavior for non-existent vars
Signed-off-by: danishprakash <danish.prakash@suse.com>
2023-06-22 15:42:55 +05:30
bb932cc840 cmd, push: expose --compression-level
This patch adds the --compression-level option to the push command.

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

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2023-06-21 14:28:16 +02:00
585d715bb9 authfile.md: add default path of file for Windows/macOS.
Signed-off-by: Tom Deseyn <tom.deseyn@gmail.com>
2023-05-30 11:16:34 +02:00
685c736185 source code comments and docs: fix typos, language, Markdown layout
- fix a/an before noun
- fix loose -> lose
- fix "the the"
- fix lets -> let's
- fix Markdown layout
- fix a few typos
- remove unnecessary text in troubleshooting.md

Signed-off-by: Erik Sjölund <erik.sjolund@gmail.com>
2023-05-22 07:52:16 +02:00
192ad70e98 run: ignore PODMAN_USERNS with --pod
the combination --pod and --userns is already blocked.  Ignore the
PODMAN_USERNS variable when a pod is used, since it would cause to
create a new user namespace for the container.

Ideally a container should be able to do that, but its user namespace
must be a child of the pod user namespace, not a sibling.  Since
nested user namespaces are not allowed in the OCI runtime specs,
disallow this case, since the end result is just confusing for the
user.

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

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2023-05-17 16:49:16 +02:00
32c2cea0f9 Remove future tense from man pages
Remove all will, would, could, should and use present tense.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-05-16 15:10:33 -04:00
edbeee5238 Add --restart flag to pod create
Add --restart flag to pod create to allow users to set the
restart policy for the pod, which applies to all the containers
in the pod. This reuses the restart policy already there for
containers and has the same restart policy options.
Add "never" to the restart policy options to match k8s syntax.
It is a synonym for "no" and does the exact same thing where the
containers are not restarted once exited.
Only the containers that have exited will be restarted based on the
restart policy, running containers will not be restarted when an exited
container is restarted in the same pod (same as is done in k8s).

Signed-off-by: Urvashi Mohnani <umohnani@redhat.com>
2023-05-02 10:29:58 -04:00
230ddbe0ca Add user mode networking feature to Windows
Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2023-04-24 17:11:54 -05:00
1f1525f2e1 support --digestfile for remote push
Wire in support for writing the digest of the pushed image to a
user-specified file.  Requires some massaging of _internal_ APIs
and the extension of the push endpoint to integrate the raw manifest
(i.e., in bytes) in the stream.

Closes: #18216
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-04-21 10:28:40 +02:00
a5dd5c20ee Capitalize all uid,gid and id words that are not options in docs
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-04-08 00:41:47 -04:00
10d2e9fdec [CI:DOCS] --creds and registries
Mention that specified credentials are only used to authenticate against
target registries (e.g., during `pull` or `build`) and are not used to
authenticat against mirrors etc.

Closes: #17185
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-04-05 13:28:46 +02:00
359f408695 [CI:DOCS] fix typo in --systemd option
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-03-31 11:07:21 +02:00
6825740fc0 docs: minor grammar fix in --volume description
Signed-off-by: Alex Willmer <alex.willmer@cgi.com>
2023-03-23 11:58:06 +00:00
9ddd4f4abd Merge pull request #17600 from sstosh/search-auth-opts
Add search --cert-dir, --creds
2023-03-20 04:00:04 -04:00
82f2f8258c Add search --cert-dir, --creds
When we searching any image at a container registry,
--cert-dir and --creds could be required
as well as push, pull, etc.

Signed-off-by: Toshiki Sonoda <sonoda.toshiki@fujitsu.com>
2023-03-15 15:01:26 +09:00
ad8a96ab95 Support running nested SELinux container separation
Currently Podman prevents SELinux container separation,
when running within a container. This PR adds a new
--security-opt label=nested

When setting this option, Podman unmasks and mountsi
/sys/fs/selinux into the containers making /sys/fs/selinux
fully exposed. Secondly Podman sets the attribute
run.oci.mount_context_type=rootcontext

This attribute tells crun to mount volumes with rootcontext=MOUNTLABEL
as opposed to context=MOUNTLABEL.

With these two settings Podman inside the container is allowed to set
its own SELinux labels on tmpfs file systems mounted into its parents
container, while still being confined by SELinux. Thus you can have
nested SELinux labeling inside of a container.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-03-13 14:21:12 -04:00
02a77d27a2 Merge pull request #17450 from danishprakash/add-group-entry
create: add entry to /etc/group via `--group-entry`
2023-02-28 21:59:59 +01:00
b8b386b7ea Merge pull request #17522 from giuseppe/relative-idmapping
libpod: support relative positions for idmaps
2023-02-20 12:54:45 +01:00
e74f60deea [CI:DOCS] Add restriction to option README
Add a note about the restriction of the use of
thre back-ticks in the md files in the options directory.
If this is not done properly, it can quietly corrupt
the compliled man pages.

[NO NEW TESTS NEEDED]
Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2023-02-17 16:29:55 -05:00
9622d25be9 Emergency fix for man pages: check for broken includes
Somehow the options/secret.md file generated corrupt md which
then generated corrupt .man files. Fix, and add a Makefile
check to prevent this from happening again.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-02-16 18:54:38 -07:00
96af9e4e0f libpod: support relative positions for idmaps
we were previously using an experimental feature in crun, but we lost
this capability once we moved to using the OCI runtime spec to specify
the volume mappings in fdcc2257df0fb0cb72d3fbe1b5aa8625955e1219.

Add the same feature to libpod, so that we can support relative
positions for the idmaps.

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

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2023-02-16 10:33:51 +01:00
828708bac2 create: add support for --group-entry
* add test
* update documentation

Signed-off-by: danishprakash <danish.prakash@suse.com>
2023-02-15 11:20:18 +05:30
0999991b20 add support for limiting tmpfs size for systemd-specific mnts
* add tests
* add documentation for --shm-size-systemd
* add support for both pod and standalone run

Signed-off-by: danishprakash <danish.prakash@suse.com>
2023-02-14 14:56:09 +05:30
fb54be2e17 [CI:DOCS] Clarify nomap constrains
Signed-off-by: salevdns <24809481+salevdns@users.noreply.github.com>
2023-02-09 10:35:43 +01:00
de63ad7044 libpod: allow userns=keep-id for root
copy the current mapping into a new user namespace, and run into a
separate user namespace.

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

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2023-02-03 12:44:30 +01:00
2bb4c7cdde libpod: support idmap for --rootfs
add a new option idmap to --rootfs that works in the same way as it
does for volumes.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2023-02-02 22:35:00 +01:00
bfc5f07d93 Cleanup documentation on --userns=auto
Fixes: https://github.com/containers/podman/issues/17134

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-01-17 17:13:36 -05:00
8db2b4b733 man: Document the interaction between --systemd and --privileged
Users need to know about this side effect.

Fixes: 5a2405ae1b3a ("Don't mount /dev/tty* inside privileged...")
Fixes: f4c81b0aa5fd ("Only prevent VTs to be mounted inside ...")
Signed-off-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org>
2023-01-16 16:23:53 +02:00
d0c89e90bf Describe copy volume options
Fixes: https://github.com/containers/podman/issues/16961

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-01-04 14:58:51 -05:00
f9e8e8cfdf Add shared --compress to man pages
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-01-03 16:39:41 -05:00
66ec8aa5d4 Merge pull request #16962 from jakecorrenti/update-pids-limit
Fixed `podman update --pids-limit`
2023-01-03 10:14:52 -05:00
479052afa6 Fixed podman update --pids-limit
Added the functionality for a user to update the PIDs limit for a
container.

Fixes: #16543

Signed-off-by: Jake Correnti <jakecorrenti+github@proton.me>
2022-12-31 18:42:47 -05:00
d27ebf2eeb Explain that relabeling/chowning of volumes can take along time
Users are surprised when chowning large volumes how long it can take
to relabel of chown the entire directory tree. This PR updates the
documentation to explain this fact to the user.

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

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-12-22 08:54:00 -05:00
9187df5b28 Unify --noheading and -n to be consistent on all commands
Helps with https://github.com/containers/podman/issues/16536

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-12-19 13:18:43 -05:00
14ee8faff1 doc: fix documentation for idmapped mounts
[CI:DOCS] fixup for https://github.com/containers/podman/pull/16837

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2022-12-15 16:33:24 +01:00
fdcc2257df libpod: use OCI idmappings for mounts
Now that the OCI runtime specs have support for idmapped mounts, let's
use them instead of relying on the custom annotation in crun.

Also add the mechanism to specify the mapping to use.  Pick the same
format used by crun so it won't be a breaking change for users that
are already using it.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2022-12-14 20:23:45 +01:00
f155a4e781 docs/options/ipc: fix list syntax
Signed-off-by: Ben Boeckel <ben.boeckel@kitware.com>
2022-12-12 18:39:26 -05:00
6f1bc98dce Merge pull request #16743 from ashley-cui/secdocs
[CI:DOCS] Clarify secret target behavior
2022-12-09 14:22:29 -05:00
59ce7cf1c0 [CI:DOCS] Clarify secret target behavior
Add documentation on how the the target option works when adding a secret to a container

Signed-off-by: Ashley Cui <acui@redhat.com>
2022-12-09 09:31:39 -05:00
2dde30b93a remote: allow --http-proxy for remote clients
The remote client should be allowed to specify if the container should
be run with the proxy env vars. It will still use the proxy vars from
the server process and not the client. This makes podman-remote more
consistent with the local version and easier to use in environments
where a proxy is required.

Fixes #16520

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-12-08 17:08:37 +01:00
7665bbc127 Remove 'you' from man pages
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-12-07 09:29:29 -05:00
d16129330d Add support for startup healthchecks
Startup healthchecks are similar to K8S startup probes, in that
they are a separate check from the regular healthcheck that runs
before it. If the startup healthcheck fails repeatedly, the
associated container is restarted.

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2022-11-28 13:30:29 -05:00