12906 Commits

Author SHA1 Message Date
34043bd81d Fix Error, empty output for info: 'VERSION'
When building releases, the definitive canonical version of podman (or
podman-remote) is needed.  Previously this was accomplished by scraping
`version/version.go`.  However, due to tooling differences across
platforms, this has proven problematic, unreliable, and hard to
maintain.

Fix this by building and caching a small golang binary who's only purpose
is to print the version number to stdout.  This not only provides a quick
and reliable way to determine the current version, it also acts as a check
on the version API vs tooling that relies on it.

Lastly, remove several `RELEASE_*` Makefile definitions which aren't
actually used anywhere.  These were originally added a very long time
ago to serve as part of a long since retired release process.  The
remaining items, were updated to make use of the new `.podmanversion`
binary on an as-required basis (i.e. not every time `make` is run).

Signed-off-by: Chris Evich <cevich@redhat.com>
2021-09-21 12:29:26 -04:00
d8d494994a Merge pull request #11662 from baude/kubenodev
Remove references to kube being development
2021-09-21 11:34:40 -04:00
f2c2e1c520 Merge pull request #11676 from rhatdan/kube
Generate kube shouldn't add podman default environment vars
2021-09-21 11:27:43 -04:00
b922e61cec Merge pull request #11650 from flouthoc/named-volume-overlay
volume: Add support for overlay on named volumes
2021-09-21 10:50:40 -04:00
185294cb8c Generate kube should'd add podman default environment vars
Currently we add the default PATH, TERM and container from Podman
to every kubernetes.yaml file. These values should not be recorded
in the yaml files.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-09-21 09:03:31 -04:00
9b5522d9ad Merge pull request #11518 from cdoern/podDevice
Pod Devices support
2021-09-21 08:40:40 -04:00
ae5de8b390 volume: Add support for overlay on named volumes
Following PR allows containers to create and mount overlays on top of
named volumes instead of mounting actual volumes via already documented `:O`.

Signed-off-by: Aditya Rajan <arajan@redhat.com>
2021-09-21 13:06:23 +05:30
8fac34b8ff Pod Device Support
added support for pod devices. The device gets added to the infra container and
recreated in all containers that join the pod.

This required a new container config item to keep track of the original device passed in by the user before
the path was parsed into the container device.

Signed-off-by: cdoern <cdoern@redhat.com>
2021-09-20 23:22:43 -04:00
b925d707fa Merge pull request #11639 from jwhonce/issues/2221
Support --format tables in ps output
2021-09-20 18:39:36 -04:00
8453c8ce63 Support --format tables in ps output
- Added tests to help ensure there is no future regressions
- Added WaitWithTimeout(int) rather than calling
  WaitWithDefaultTimeout() multiple times
- Exposed DefaultWaitTimeout to allow test to use a multiplier

Fixes #2221

Signed-off-by: Jhon Honce <jhonce@redhat.com>
2021-09-20 13:51:27 -07:00
7e8ce73c15 Merge pull request #11660 from rhatdan/docs
Add podman image/container inspect man pages
2021-09-20 14:35:45 -04:00
791458605a Merge pull request #11630 from rhatdan/timeout
Add support for retrieving system service --timeout
2021-09-20 14:21:44 -04:00
fff178fe51 Merge pull request #11601 from cdoern/mapOptions
Created MapOptions for PodCreate
2021-09-20 14:02:42 -04:00
a2b3674143 Merge pull request #11649 from Luap99/machine-dns
podman machine: use gvproxy for host.containers.internal
2021-09-20 13:48:42 -04:00
b700fe22fd Merge pull request #11644 from rhatdan/now
Add podman machine init --now option
2021-09-20 13:47:43 -04:00
61217f3ba9 Remove references to kube being development
At this point and even though we are always improving the play and
generate kube functions, I would say it no longers needs to be denoted
as under development.

[NO TESTS NEEDED]

Signed-off-by: Brent Baude <bbaude@redhat.com>
2021-09-20 12:47:15 -05:00
4cdffd0714 Merge pull request #11656 from Luap99/compat-id
compat API: /images/json prefix image id with sha256
2021-09-20 12:34:44 -04:00
8ccaebb853 Merge pull request #11661 from umohnani8/docs
[CI:DOCS] Add link to skopeo delete in podman rmi
2021-09-20 12:31:43 -04:00
b74edfb0a1 Add support for retrieving system service --timeout
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-09-20 12:10:14 -04:00
3221f50a45 Add podman image/container inspect man pages
[NO TESTS NEEDED] since this is really a docs change.

Concludes: https://github.com/containers/podman/pull/11620

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-09-20 12:06:26 -04:00
665b451e51 [CI:DOCS] Add link to skopeo delete in podman rmi
Add a note pointing to skopeo delete for when
users want to delete an image in a remote registry.

Signed-off-by: Urvashi Mohnani <umohnani@redhat.com>
2021-09-20 10:58:18 -04:00
cc6a85bcde Merge pull request #11652 from vrothberg/vendor-common
vendor c/common@main
2021-09-20 10:35:44 -04:00
f7d7fc2c8c Merge pull request #11651 from vrothberg/fix-11557
remote untag: support digests
2021-09-20 10:28:45 -04:00
5098124570 vendor c/common@main
Finalizes the linked BZ to fix passing down custom authfiles during auto
updates.  Also fixes the if-newer pull policy.

[NO TESTS NEEDED] for now validated manually.  There's a TODO to add a
new system test that I did not find time for before PTO.

BZ: bugzilla.redhat.com/show_bug.cgi?id=2000943
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2021-09-20 15:07:41 +02:00
92ee2f372b remote untag: support digests
Fix a bug when remotely untagging an image via tag@digest.
The digest has been lost in the remote client and hence led
to a wrong behaviour on the server.

Fixes: #11557
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2021-09-20 15:06:37 +02:00
b906ecbb5b Merge pull request #11648 from giuseppe/raise-move-process-to-scope-only-with-cgroupv2
utils: raise warning only on cgroupv2
2021-09-20 09:05:43 -04:00
cb077c968d Created MapOptions for PodCreate
MapOptions take the pod and container create options, assigning matching values from infra
back to the pod for the Libpod API. This function, unlike the previous one, does not require any
manual additions when new options are added since it uses the structs JSON tags, this is a more modular approach.

Signed-off-by: cdoern <cdoern@redhat.com>
2021-09-20 08:33:15 -04:00
5242030ac2 compat API: /images/json prefix image id with sha256
Docker adds the `sha256:` prefix to the image ID, so our compat endpoint
has to do this as well.

Fixes #11623

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2021-09-20 13:47:29 +02:00
cf28dab9f1 podman machine: use gvproxy for host.containers.internal
Let the gvproxy dns server handle the host.containers.internal entry.
Support for this is already added to gvproxy. [1]

To make sure the container uses the dns response from gvproxy we should
not add host.containers.internal to /etc/hosts in this case.

[NO TESTS NEEDED] podman machine has no tests :/

Fixes #11642

[1] 1108ea4516

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2021-09-20 11:31:26 +02:00
eea5d25126 utils: return error message from StartTransientUnit
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2021-09-20 09:42:35 +02:00
4caca09698 utils: raise warning only on cgroupv2
if it is not running on cgroup v2, print only a debug message since
rootless users cannot create the cgroup.

commit 9c1e27fdd536f6026efe3da4360755a3e9135ca8 introduced the regression.

[NO TESTS NEEDED]

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2021-09-20 09:38:24 +02:00
74ad05396b Add podman machine init --now option
Once we have this option, the new documentation from users becomes
a little simpler.

brew install podman
podman machine init --now
podman run ...

--now option is based off of `systemctl enable XYZ.service --now`

[NO TESTS NEEDED] The infrastructure has not been setup yet to test
podman machine init.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-09-19 05:53:08 -04:00
ddb3844511 Merge pull request #11638 from edsantiago/bats
System tests: cleanup, and remove obsolete skips
2021-09-18 15:13:05 -04:00
a9e95eb327 Merge pull request #11628 from Luap99/remove-unsued-code
Remove unused code from libpod
2021-09-18 07:46:04 -04:00
fc4a47e0e7 Merge pull request #11617 from ashley-cui/ssh
[NO TESTS NEEDED] Add username flag for machine ssh
2021-09-18 06:43:03 -04:00
22df773f77 System tests: cleanup, and remove obsolete skips
* 070-build:
  - remove workaround for #9567, which is closed.
  - add many more cases to the ignorefile test,
    to test complicated special cases of Buildah PR 3486.

* 160-volumes:
  - remove a skip_if_remote, volumes now work on remote
  - use a random name for tarball, and clean up when
    done using it. This fixes a gating-test failure
    (test runs as root, then rootless, and rootless
    can't clobber root's file).

Signed-off-by: Ed Santiago <santiago@redhat.com>
2021-09-17 14:29:18 -06:00
e3e9e5175f Add username flag for machine ssh
allow users to specify what username to use when ssh-ing into the vm.
If the username flag is set, the username will be the flag value. If the
flag is not set and the the vm name is specified, the default user of
the vm will be used. if the flag is not set, and the vm name is not
specified, then the username of the default connection will be used.

Signed-off-by: Ashley Cui <acui@redhat.com>
2021-09-17 13:33:56 -04:00
08e1bb54c3 Merge pull request #11607 from Luap99/ipvlan
CNI: add ipvlan driver support and macvlan modes
2021-09-17 10:45:18 -04:00
c692f7a18b Remove unused code from libpod
The libpod package should only compile on linux. The remote client
should never try to import this package.

Since these files do not add any value we should remove them, this
prevents people from accidentally importing this package because it would
fail to compile on windows/macos.

[NO TESTS NEEDED]

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2021-09-17 13:57:38 +02:00
9a5987cf6a Merge pull request #11603 from rhatdan/truncate
Add no-trunc support to podman-events
2021-09-17 07:02:52 -04:00
c6ae5c7961 Merge pull request #11612 from rhatdan/docs
Fix up build the docs site
2021-09-17 06:35:50 -04:00
f7705c44fa Merge pull request #11620 from edsantiago/doc_cleanup
[CI:DOCS] markdown cleanup
2021-09-17 06:34:51 -04:00
84c61b7d36 Merge pull request #11606 from giuseppe/always-move-pause-process-to-scope
runtime: move pause process to scope
2021-09-17 04:35:58 -04:00
62350fed61 [CI:DOCS] markdown cleanup
* podman-inspect: make references be live links, not a static
  list. Also, remove container- and image-inspect, because
  those are NOPs.

* podman-pull: add a missing right-paren

* podman-search, podman: remove unwanted indentation from
  some file descriptions. Markdown indentation renders as
  one very very long line, requiring the user to use a
  horizontal scroll bar to read the text. I searched
  using grep '^    ' and eyeball-looking for text that
  doesn't look like one-line code examples, and see
  no more, but eyeball checks are fragile.

One bug remains: MyST renders mailto: links uglily. I can find
no way to fix this other than patching the source code.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2021-09-16 15:59:14 -06:00
613ef220f3 Fix up build the docs site
[NO TESTS NEEDED]

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2021-09-16 17:41:00 -04:00
6cf13c3dbf Merge pull request #11602 from Luap99/netname
Do not allow network modes to be used as network names
2021-09-16 17:17:08 -04:00
0acf540304 Merge pull request #11605 from Luap99/hosts
Only add 127.0.0.1 entry to /etc/hosts with --net=none
2021-09-16 17:15:08 -04:00
a65000bbb7 Merge pull request #11614 from Luap99/podman-io
[CI:DOCS] Use a new markdown converter for sphinx
2021-09-16 17:12:07 -04:00
7ca666f474 Use a new markdown converter for sphinx
Recommonmark has many issues and is deprecated. The recommended
alternative is MyST-Parser. [1]

The myst parser looks great, it also correctly parses tables and adds the
correct links.

To test locallay run:
```
cd docs
rm -rf build/
\# install build deps
sudo dnf install python3-sphinx && pip install myst-parser
make html
python -m http.server 8000 --directory build/html
\# Now check in your browser if it looks good to you
```

[1] https://github.com/readthedocs/recommonmark/issues/221

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2021-09-16 21:10:13 +02:00
a2c8b5d9d6 runtime: move pause process to scope
make sure the pause process is moved to its own scope as well as what
we do when we join an existing user+mount namespace.

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

[NO TESTS NEEDED]

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2021-09-16 20:17:40 +02:00