16724 Commits

Author SHA1 Message Date
9c3d8bb494 cmd/podman: add support for checkpoint images
This patch extends the podman run command with support for checkpoint
images. When `podman run` is invoked with an image that contains
a checkpoint, it would restore the container from that checkpoint.

Example:
    podman run -d --name looper busybox /bin/sh -c \
	    'i=0; while true; do echo $i; i=$(expr $i + 1); sleep 1; done'

    podman container checkpoint --create-image checkpoint-image-1 looper

    podman run checkpoint-image-1

Signed-off-by: Radostin Stoyanov <radostin@redhat.com>
2022-09-29 13:33:07 +01:00
b17d8ff46d restore: make IsCheckpointImage reusable
Podman allows to store a container checkpoints as an images.
This patch makes the check that is used to recognise such checkpoint
images reusable by moving it in utils. This functionality will be reused
in a subsequent patch to extend the `podman run` command with support
for checkpoint images.

Signed-off-by: Radostin Stoyanov <radostin@redhat.com>
2022-09-29 13:23:43 +01:00
f52feded3c Merge pull request #15988 from sstosh/manifest-annotate-remote
remote: fix manifest add --annotation
2022-09-29 13:22:22 +02:00
3269ee9fea Merge pull request #15981 from edsantiago/dont_storageopt
System tests: stop deep-checking log-level
2022-09-29 13:10:44 +02:00
2489a94b98 Merge pull request #15971 from containers/dependabot/go_modules/github.com/container-orchestrated-devices/container-device-interface-0.5.2
build(deps): bump github.com/container-orchestrated-devices/container-device-interface from 0.5.1 to 0.5.2
2022-09-29 12:20:59 +02:00
64ca617a42 Merge pull request #15962 from dfr/freebsd-volume
Add volume support for FreeBSD
2022-09-29 12:18:25 +02:00
32f54a81ed remote: fix manifest add --annotation
* `manifest add --annotation option` adds annotations
  field on remote environment.
* `manifest inspect` prints annotations field
  on remote environment.

Fixes: #15952

Signed-off-by: Toshiki Sonoda <sonoda.toshiki@fujitsu.com>
2022-09-29 18:14:41 +09:00
b7eee0b2ce Merge pull request #15917 from cevich/check_new_go_code
[CI:BUILD] Check new go code
2022-09-29 01:12:03 +02:00
40b28dcf4d Merge pull request #15968 from piotr-sk/fix/kube_play_liveness_probe_path
fix: kube play liveness probe http path
2022-09-28 22:29:28 +02:00
496d4c7533 System tests: stop deep-checking log-level
I was testing --log-level by --storage-opt=mount_program=/bin/false

Stop doing that. It's just constantly breaking everything (#15698
and #15977).

I am violently of the opinion that a command-line option must
not destroy a user's system (except for --set-something, --config,
something that makes it very very clear that it is a lasting
change). I seem to be in the minority on this opinion. So, I
give up.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-09-28 09:30:23 -06:00
ba70dd5ecf build(deps): bump github.com/container-orchestrated-devices/container-device-interface
Bumps [github.com/container-orchestrated-devices/container-device-interface](https://github.com/container-orchestrated-devices/container-device-interface) from 0.5.1 to 0.5.2.
- [Release notes](https://github.com/container-orchestrated-devices/container-device-interface/releases)
- [Commits](https://github.com/container-orchestrated-devices/container-device-interface/compare/v0.5.1...v0.5.2)

---
updated-dependencies:
- dependency-name: github.com/container-orchestrated-devices/container-device-interface
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-09-28 12:12:48 +00:00
66517d86a7 fix: kube play liveness probe http path
Use the default / for http probe path.
Update to URI schemes ensuring lowercase

Signed-off-by: Piotr <piotr.skoczylas@gmail.com>
2022-09-28 09:56:56 +02:00
dca5ead2d7 Merge pull request #15946 from rhatdan/kube
Default missing hostPort to containerPort is defined in kube.yaml
2022-09-27 22:21:54 +02:00
b794b61817 Merge pull request #15937 from rhatdan/man
[CI:DOCS] Add SELinux information about boolean for using random devices
2022-09-27 20:12:43 +02:00
ecf05dd7a7 Merge pull request #15908 from edsantiago/systemd_tty_test
System tests: light cleanup
2022-09-27 20:09:47 +02:00
a225cb5953 Merge pull request #15958 from piotr-sk/fix/kube_play_liveness_probe
fix: liveness check with http probe
2022-09-27 20:06:53 +02:00
f5fc0960e5 Default missing hostPort to containerPort is defined in kube.yaml
If user does not specify hostPort in a kube.yml file but does specify
a containerPort, then the hostPort should default to the containerPort.

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

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-09-27 14:04:24 -04:00
cbc7185d1f Merge pull request #15896 from edsantiago/dont_install_tools
CI: only make install.tools when needed
2022-09-27 13:09:18 -04:00
359e397443 libpod: Add volume support for FreeBSD
[NO NEW TESTS NEEDED]

Signed-off-by: Doug Rabson <dfr@rabson.org>
2022-09-27 16:31:40 +01:00
abe8dad344 libpod: Factor out usage of unix.MNT_DETACH from (*Volume).unmount
There is an existing wrapper for unix.Unmount(..., MNT_DETACH) in
util_linux.go but that filters all errors and for volumes, we only want
to filter EINVAL. The existing libpod.Unmount seems to only have one
call site so perhaps these can be merged.

[NO NEW TESTS NEEDED]

Signed-off-by: Doug Rabson <dfr@rabson.org>
2022-09-27 16:31:40 +01:00
9de2a5ff79 libpod: Move volume_internal_linux.go to volume_internal_common.go
[NO NEW TESTS NEEDED]

Signed-off-by: Doug Rabson <dfr@rabson.org>
2022-09-27 16:31:40 +01:00
065474755b libpod: Move runtime_volume_linux.go to runtime_volume_common.go
[NO NEW TESTS NEEDED]

Signed-off-by: Doug Rabson <dfr@rabson.org>
2022-09-27 16:31:40 +01:00
95cb14aff2 fix: liveness check with http probe
Ensure kubernetes default parameters are respected.
Additional curl parameter enforces returning error for HTTP error codes.
Use build-in HealthCheckOnFailureAction instead of killing the container
while executing the probe.

Signed-off-by: Piotr <piotr.skoczylas@gmail.com>
2022-09-27 16:52:54 +02:00
23a30661ad Merge pull request #15948 from ashley-cui/osxcross
Cirrus: Build pkginstaller in CI
2022-09-27 16:37:42 +02:00
3e80931529 System tests: light cleanup
Followup to #15895:
 - add a normal-case test, to ensure that --privileged without
   systemd continues to pass through /dev/ttyN devices
 - explain why we die() if host has no ttyN devices
 - I find grep -vx slightly easier to read than sed backslash-slash
 - run cleanup with '-t 0', to shave ten seconds from CI run

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-09-27 05:53:18 -06:00
0fb95f95d2 CI: only make install.tools when needed
Reintroduce .install.foo targets into Makefile, and invoke
only the bare-minimum ones needed for each individual CI
step in setup_environment.sh.

Also add a retry to the golangci-lint curl, in hopes of
dealing with network flakes. And remove the -f (fail)
because it produces unhelpful logs.

Reason: saw about 25% CI flakes yesterday due to the golangci-lint
fetch, something about a timeout, and this was especially frustrating
because none of the steps actually needed lint. Quick reminder:
avoid network fetches unless absolutely necessary.

Fixes: #15892

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-09-27 05:52:34 -06:00
f51aeb45d4 Merge pull request #15916 from ashley-cui/machstarting
Fix machine starting state
2022-09-27 10:47:48 +02:00
98e2627884 Merge pull request #15471 from cdoern/ssh
podman machine ssh handling
2022-09-27 02:15:42 +02:00
2e4e1bb97c podman machine ssh handling
add the key used in newly initialized machines to the user's known_hosts file. This ensures that golang will be able to ssh into the machine using
podman-remote. Also, remove the /dev/null redirection for podman machine ssh's known_hosts file.

resolves #15347

Signed-off-by: Charlie Doern <cdoern@redhat.com>
Signed-off-by: cdoern <cbdoer23@g.holycross.edu>
2022-09-26 18:35:01 -04:00
53d604182f Cirrus: Build pkginstaller in CI
Build unsigned pkginstaller in OSX Cross CI task & upload as an artifact.

Signed-off-by: Ashley Cui <acui@redhat.com>
2022-09-26 17:24:35 -04:00
5fc6d95a94 Merge pull request #15941 from mheon/bump_430_rc1
Bump to v4.3.0-RC1
2022-09-26 21:37:10 +02:00
c1ae7f1934 Add SELinux information about boolean for using random devices
Fixes: https://github.com/containers/podman/issues/15930

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-09-26 15:07:17 -04:00
a0c0971e63 Merge pull request #15933 from vrothberg/fix-15879
auto-update: validate container image
2022-09-26 20:45:30 +02:00
aaeabb0e8c Merge pull request #15940 from edsantiago/docs_dedup_env_file
[CI:DOCS] Man pages: refactor common options: --env-file
2022-09-26 19:48:19 +02:00
051eb43c69 Merge pull request #15907 from Luap99/compat-net-opts
compat API: network inspect do not show isolate option
2022-09-26 19:21:16 +02:00
f32b02c7b5 Bump to v4.3.0-dev
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2022-09-26 13:10:27 -04:00
f818eb4a5e Bump to v4.3.0-RC1
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
v4.3.0-rc1
2022-09-26 13:10:05 -04:00
527fc409e5 Cirrus: Add golang code consistency check script
Depends on #15893

Fixes: #15913

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-09-26 11:57:20 -04:00
f6724116ab Man pages: refactor common options: --env-file
Another easy one. Option is only present in these three man pages.

I took the liberty of changing the "See note" text, making it
the same as --env. I also took the liberty of hyphenating
"line-delimited" because that's the correct thing to do.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-09-26 09:17:55 -06:00
d5e13a3a90 Merge pull request #15938 from edsantiago/docs_dedup_env
[CI:DOCS] Man pages: refactor common options: --env
2022-09-26 17:15:38 +02:00
7bc36602f6 auto-update: validate container image
Auto updates using the "registry" policy require container to be created
with a fully-qualified image reference.  Short names are not supported
due the ambiguity of their source registry.  Initially, container
creation errored out for non FQN images but it seems that Podman has
regressed.

Fixes: #15879
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2022-09-26 17:07:05 +02:00
cf6136ffa5 Merge pull request #15813 from praveenkumar/podman-remote-container-file
[CI:BUILD] Contrib: Add containerfile to create podman-remote binary image
2022-09-26 16:32:30 +02:00
fa18d35e89 Man pages: refactor common options: --env
Only among podman create, exec, run. The same option in
podman build, generate-systemd, and secret-create is too
different.

Should be a trivial one to review, the only difference is
a period at the end of one sentence. And, of course, the
"See Environment note" applies only to podman-create and
run, not exec, so it can't be deduplicated.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-09-26 08:27:54 -06:00
a399e58cfb Merge pull request #15936 from edsantiago/docs_dedup_sigproxy
[CI:DOCS] Man pages: Refactor common options: --sig-proxy
2022-09-26 16:27:21 +02:00
cad59a12b9 Merge pull request #15935 from edsantiago/xref_manpage_title
[CI:DOCS] man page xref: verify page title
2022-09-26 15:42:47 +02:00
911ceb823a Man pages: Refactor common options: --sig-proxy
Unusually, I discarded the podman-run version and went with
the one common to attach and start. (The defaults are left
out of the common file, because 'start' is different by
necessity). Please review extra-carefully to make sure
the new wording applies to podman-run, in particular
the "non-TTY mode" words.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-09-26 07:25:10 -06:00
a00376111e Merge pull request #15926 from eriksjolund/remove_redundant_log_output
Remove redundant log message
2022-09-26 14:32:34 +02:00
0a4a81856a Merge pull request #15893 from cevich/ioutil_whine
[CI:BUILD] Cirrus: Catch use of deprecated ioutils package
2022-09-26 14:29:56 +02:00
fde4d21be5 man page xref: verify page title
Issue #15923 should have never happened: the problem should've
been autodetected. Make it so henceforth (and fix another
existing discrepancy)

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-09-26 06:19:15 -06:00
1d6147fa13 Merge pull request #15924 from eriksjolund/fix_podman_system_service_man_page
[CI:DOCS] man pages: fix incorrect title
2022-09-26 13:48:32 +02:00