8781 Commits

Author SHA1 Message Date
2e3928ee17 Merge pull request #7193 from vrothberg/fix-7190
podman.service: drop install section
2020-08-03 10:07:51 -04:00
70c75bc113 Merge pull request #7097 from QiWang19/usagedate
[CI:DOCS] apiv2 fix volumes not included field
2020-08-03 10:05:07 -04:00
af3676f772 Merge pull request #7194 from vrothberg/systetemd-auto-update
Systemd: install auto-update service and timer
2020-08-03 10:02:07 -04:00
52580b9dc7 Merge pull request #7076 from alvistack/master-linux-amd64
Speedup static build by utilizing CI cache on `/nix` folder
2020-08-03 09:22:10 -04:00
96ece0ca56 Merge pull request #7188 from zhangguanzhang/network-404
API returns 500 in case network is not found instead of 404
2020-08-03 09:13:40 -04:00
de5eb38311 Merge pull request #7191 from openSUSE/printf
Remove some unnecessary []byte to string conversions
2020-08-03 09:10:53 -04:00
41358f5ea0 Merge pull request #7158 from rhatdan/commit
Handle single character images
2020-08-03 09:08:02 -04:00
efcc2f5b18 Install auto-update services for users
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-08-03 13:12:07 +02:00
4384de9e6b Fix test failure regarding unpackaged files.
Signed-off-by: Peter Oliver <git@mavit.org.uk>
2020-08-03 13:12:06 +02:00
f3e01de3a3 Install auto-update systemd service and timer.
Signed-off-by: Peter Oliver <git@mavit.org.uk>
2020-08-03 13:12:06 +02:00
7dadf1b46e podman.service: drop install section
podman.service is socket activated through podman.socket. It should not
have its own [Install] section, it does not make sense to systemctl
enable podman.service.

This leads to podman.service always running on a Debian system, as
Debian's policy is to enable/start running services by default.

We don't want a daemon :^)

Fixes: #7190
Reported-by: @martinpitt
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-08-03 09:48:13 +02:00
fef3e2da6a Remove some unnecessary []byte to string conversions
Some calls to `Sprintf("%s")` can be avoided by using direct string
type assertions.

Signed-off-by: Sascha Grunert <sgrunert@suse.com>
2020-08-03 09:13:04 +02:00
bfd34542f4 Merge pull request #7141 from rhafer/image_descr_test
Add test case for description being present in search result
2020-08-03 03:06:24 -04:00
daaccf8896 Speedup static build by utilizing CI cache on /nix folder
Signed-off-by: Wong Hoi Sing Edison <hswong3i@gmail.com>
2020-08-03 11:52:18 +08:00
45b100d21c API returns 500 in case network is not found instead of 404
Signed-off-by: zhangguanzhang <zhangguanzhang@qq.com>
2020-08-02 22:21:28 +08:00
f4d4bd2288 Merge pull request #7181 from Luap99/systemd-unit-path
[CI:DOCS] Change recommended systemd unit path for root.
2020-08-02 07:13:50 -04:00
b425a4f4ac Merge pull request #7171 from jwhonce/wip/varlink_timeout
Fix podman service --valink timeout
2020-08-01 09:17:35 -04:00
de460bf978 Merge pull request #7177 from mheon/there_can_be_only_one
Ensure libpod/define does not include libpod/image
2020-08-01 09:14:53 -04:00
af2a1327d1 Merge pull request #7165 from jwhonce/issues/7008
Add versioned _ping endpoint
2020-08-01 09:12:07 -04:00
0d064a0f29 Merge pull request #7178 from mheon/update_master_204
[CI:DOCS] Update master README and release notes for v2.0.4
2020-08-01 09:01:40 -04:00
c90ad68fa1 Change recommended systemd unit path for root.
`/usr/lib/systemd/system` should only be used by the package manager
administrators should use: `/etc/systemd/system` or
`/usr/local/lib/systemd/system`

see: man systemd.unit

Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
2020-08-01 14:55:48 +02:00
4c75fe3f70 Merge pull request #7152 from Luap99/fix#7087
fix pod creation with "new:" syntax
2020-07-31 18:35:44 -04:00
66f1ec64ab Update master README and release notes for v2.0.4
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-07-31 17:24:22 -04:00
e3ced7217f Ensure libpod/define does not include libpod/image
The define package under Libpod is intended to be an extremely
minimal package, including constants and very little else.
However, as a result of some legacy code, it was dragging in all
of libpod/image (and, less significantly, the util package).
Fortunately, this was just to ensure that error constants were
not duplicating, and there's nothing preventing us from
importing in the other direction and keeping libpod/define free
of dependencies.

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-07-31 17:17:56 -04:00
02eefe650c Fix podman service --valink timeout
Documentation and unit files call for a millisecond timeout while the
code was using a second resolution.  Code change is smaller given
varlink has been deprecated.

Signed-off-by: Jhon Honce <jhonce@redhat.com>
2020-07-31 10:22:27 -07:00
cff727d488 Add versioned _ping endpoint
Fixes #7008

Signed-off-by: Jhon Honce <jhonce@redhat.com>
2020-07-31 10:19:23 -07:00
949dfc85a0 fix pod creation with "new:" syntax
When you execute podman create/run with the --pod new:<name> syntax
the pod was created but the namespaces where not shared and
therefore containers could not communicate over localhost.

Add the default namespaces and pass the network options to the
pod create options.

Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
2020-07-31 18:27:49 +02:00
7a15be546a Merge pull request #7168 from QiWang19/exec-fds
Fix close fds of exec --preserve-fds
2020-07-31 11:34:23 -04:00
54256fbe78 Make search --no-trunc work for podman remote
The HTTP API for image search was still lacking support of the NoTrunc
parameter.

Signed-off-by: Ralf Haferkamp <rhafer@suse.com>
2020-07-31 15:39:57 +02:00
bcbb5f9963 API: Fix 'podman image search` missing description
`podman image search` returned wrong results for the image "Description" as
it was mapped to the wrong field ("ID") in the search results.
Basically cherry-picked into the api from
commit cf5c63b5c492e41d72b6e3b6d75b5f39b0a957fd.

Signed-off-by: Ralf Haferkamp <rhafer@suse.com>
2020-07-31 15:39:57 +02:00
ad2efbe9e1 Add test case for description being present in search result
Test for a specific static image and match the description to avoid
regression like https://github.com/containers/podman/pull/7131

Signed-off-by: Ralf Haferkamp <rhafer@suse.com>
2020-07-31 15:39:57 +02:00
3fccb699e4 Fix close fds of exec --preserve-fds
Fix the closing of fds from --preserve-fds to avoid the operation on unrelated fds.

Signed-off-by: Qi Wang <qiwan@redhat.com>
2020-07-31 08:27:12 -04:00
3cf8237bc0 Merge pull request #7120 from QiWang19/preserve-fd
Fix close fds of run --preserve-fds
2020-07-31 08:25:05 -04:00
bb96c8918b Merge pull request #7164 from giuseppe/volumes-chown-no-recurse
volumes: do not recurse when chowning
2020-07-31 07:19:02 -04:00
e911875b6a Merge pull request #7162 from giuseppe/add-rootless-checks
rootless: do not ignore errors if mappings are specified
2020-07-31 06:16:14 -04:00
10627228be volumes: do not recurse when chowning
keep the file ownership when chowning and honor the user namespace
mappings.

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

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2020-07-31 10:57:03 +02:00
0e009d5f80 Merge pull request #7159 from ashley-cui/runningfor
add {{.RunningFor}} placeholder in ps --format
2020-07-31 03:24:35 -04:00
1b784b4c35 Merge pull request #7161 from Luap99/fix#7160
fix swapped mem_usage/percent fields
2020-07-30 22:03:59 -04:00
0785d6af15 Handle single character images
Currently you can only specify multiple character for image names
when executing podman-remote commit

podman-remote commit a b
Will complete, but will save the image without a name.

podman-remote commit a bb
Works.

This PR fixes and now returns an error if the user doees not specify an
image name to commit to.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-07-30 17:42:15 -04:00
d188b2fe22 rootless: add a check for the host id included in the range
add a check to verify whether the additional IDs also contain the host
ID.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2020-07-30 23:16:50 +02:00
2764d18751 fix swapped mem_usage/percent fields
Correct the wrong field assignment in `podman stats --format=json`.

Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
2020-07-30 22:36:59 +02:00
d86ef45441 rootless: child exits immediately on userns errors
if the parent process failed to create the user namespace, let the
child exit immediately.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2020-07-30 21:46:04 +02:00
8408cfd35c rootless: do not ignore errors if mappings are specified
when setting up the user namespace do not ignore errors from
newuidmap/newgidmap if there are mappings configured.

The single user mapping is a fallback only when there are not mappings
specified for the user.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2020-07-30 21:43:09 +02:00
8e6a6197db add {{.RunningFor}} placeholder in ps --format
For docker compatibility

Signed-off-by: Ashley Cui <acui@redhat.com>
2020-07-30 15:33:22 -04:00
57967414ae fix close fds of run --preserve-fds
Test flakes mentioned in #6987 might be caused by uncorrect closing of file descriptor.
Fix the code to close file descriptors for podman run since it may close those used by other processes.

Signed-off-by: Qi Wang <qiwan@redhat.com>
2020-07-30 15:32:39 -04:00
4132b71478 Merge pull request #7156 from zhangguanzhang/master
fix podman system df format error
2020-07-30 15:14:49 -04:00
ca2bda6420 Merge pull request #7155 from mheon/fix_rmi_force
Ensure that 'rmi --force' evicts Podman containers
2020-07-30 14:52:59 -04:00
b4fa2c2517 fix podman system df format error
Signed-off-by: zhangguanzhang <zhangguanzhang@qq.com>
2020-07-31 01:40:42 +08:00
9f5a11cacc Ensure that 'rmi --force' evicts Podman containers
The logic for `podman rmi --force` includes a bit of code that
will remove Libpod containers using Libpod's container removal
logic - this ensures that they're cleanly and completely removed.
For other containers (Buildah, CRI-O, etc) we fall back to
manually removing the containers using the image from c/storage.

Unfortunately, our logic for invoking the Podman removal function
had an error, and it did not properly handle cases where we were
force-removing an image with >1 name. Force-removing such images
by ID guarantees their removal, not just an untag of a single
name; our code for identifying whether to remove containers did
not proper detect this case, so we fell through and deleted the
Podman containers as storage containers, leaving traces of them
in the Libpod DB.

Fixes #7153

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-07-30 12:01:05 -04:00
05b3e0e16b Merge pull request #7151 from edsantiago/bats
System tests: new system-df and passwd tests
2020-07-30 10:43:12 -04:00