9724 Commits

Author SHA1 Message Date
c8f0e1dab6 Merge pull request #8146 from vrothberg/image-mounts
new "image" mount type
2020-10-29 18:15:24 +01:00
e439aec4fa Merge pull request #8046 from cevich/simplify_environment
Cirrus: Simplify setting/passing env. vars.
2020-10-29 18:07:29 +01:00
6d72e7611e Merge pull request #8165 from edsantiago/move_from_dockerio
Move from docker.io
2020-10-29 18:00:33 +01:00
7485005206 Merge pull request #8178 from rhatdan/exists
NewFromLocal can return multiple images
2020-10-29 17:04:05 +01:00
b6aa9c1077 Merge pull request #8173 from giuseppe/improve-cannot-reexec-error
rootless: improve error message if cannot join namespaces
2020-10-29 16:15:30 +01:00
65a618886e new "image" mount type
Add a new "image" mount type to `--mount`.  The source of the mount is
the name or ID of an image.  The destination is the path inside the
container.  Image mounts further support an optional `rw,readwrite`
parameter which if set to "true" will yield the mount writable inside
the container.  Note that no changes are propagated to the image mount
on the host (which in any case is read only).

Mounts are overlay mounts.  To support read-only overlay mounts, vendor
a non-release version of Buildah.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-10-29 15:06:22 +01:00
3ba77a5618 Cirrus: Simplify setting/passing env. vars.
Test VMs by design are to be single-purpose, single-use, and
readily disposable.  Therefore it's unnecessary to overcomplicate
storage of runtime environment variables.  This commit makes these
points clear, and reorganizes all CI-related env. vars on the system
into a single location, `/etc/ci_environment`.  This file is then
automatically loaded, and variables exported, (by `lib.sh`) from
`runner.sh` prior to executing all forms of testing.

Signed-off-by: Chris Evich <cevich@redhat.com>
2020-10-29 09:02:31 -04:00
fdd32604cf Merge pull request #8161 from afbjorklund/podman-remote-host-hash
Support hashed hostnames in the known_hosts file
2020-10-29 06:31:20 -04:00
cfc41b32fd rootless: improve error message if cannot join namespaces
if podman failed to join the rootless namespaces, give users a better
errror message and possible solution.

Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1891220

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2020-10-29 08:49:40 +01:00
cce6c6cd40 Merge pull request #8163 from giuseppe/clean-path
libpod: clean paths before check
2020-10-29 03:31:19 -04:00
464aa36b0c Merge pull request #8081 from mheon/pod_degraded
Add a Degraded state to pods
2020-10-28 16:10:33 -04:00
99d3e2e9d7 NewFromLocal can return multiple images
If you use additional stores and pull the same image into
writable stores, you can end up with the situation where
you have the same image twice. This causes image exists
to return the wrong error.  It should return true in this
situation rather then an error.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-10-28 16:02:53 -04:00
6ad768852a libpod: clean paths before check
clean the paths before checking whether its value is different than
what is stored in the db.

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

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2020-10-28 20:49:03 +01:00
20e104351d move from docker.io
Followon to #7965 (mirror registry). mirror.gcr.io doesn't
cache all the images we need, and I can't find a way to
add to its cache, so let's just use quay.io for those
images that it can't serve.

Tools used:
  skopeo copy --all docker://docker.io/library/alpine:3.10.2 \
                    docker://quay.io/libpod/alpine:3.10.2

...and also:

    docker.io/library/alpine:3.2
    docker.io/library/busybox:latest
    docker.io/library/busybox:glibc
    docker.io/library/busybox:1.30.1
    docker.io/library/redis:alpine
    docker.io/libpod/alpine-with-bogus-seccomp:label
    docker.io/libpod/alpine-with-seccomp:label
    docker.io/libpod/alpine_healthcheck:latest
    docker.io/libpod/badhealthcheck:latest

Since most of those were new quay.io/libpod images, they required
going in through the quay.io GUI, image, settings, Make Public.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-10-28 13:16:37 -06:00
e04e567b96 Merge pull request #8175 from mheon/interactive_attach_chan
Ensure that attach ready channel does not block
2020-10-28 14:53:34 -04:00
53fe386da0 Cirrus: Use google mirror for docker.io
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-10-28 12:25:53 -06:00
5d48606dae Cirrus: Always record runc/crun versions
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-10-28 12:24:06 -06:00
2cf443fd41 Ensure that attach ready channel does not block
We only use this channel in terminal attach, and it was not a
buffered channel originally, so it would block on trying to send
unless a receiver was ready. In the non-terminal case, there was
no receiver, so attach blocked forever. Buffer the channel for a
single bool so that it will never block, even if unused.

Fixes #8154

Signed-off-by: Matthew Heon <mheon@redhat.com>
2020-10-28 11:32:31 -04:00
4d87306fbe Merge pull request #8157 from rhatdan/volumes
Add test cases to cover podman volume
2020-10-28 08:55:16 -04:00
7149a7cb39 Merge pull request #8102 from ashley-cui/inspect
Add pod, volume, network to inspect package
2020-10-27 17:04:44 -04:00
26c09291a3 Merge pull request #8121 from baude/clioptsresources
set resources only when specified
2020-10-27 15:24:58 -04:00
61deec451f Add pod, volume, network to inspect package
podman inspect only had the capabilities to inspect containers and images. if a user wanted to inspect a pod, volume, or network, they would have to use `podman network inspect`, `podman pod inspect` etc. Docker's cli allowed users to inspect both volumes and networks using regular inspect, so this commit gives the user the functionality

If the inspect type is not specified using --type, the order of inspection is:

containers
images
volumes
networks
pods

meaning if container that has the same name as an image, podman inspect would return the container inspect.

To avoid duplicate code, podman network inspect and podman volume inspect now use the inspect package as well. Podman pod inspect does not because podman pod inspect returns a single json object while podman inspect can return multiple)

Signed-off-by: Ashley Cui <acui@redhat.com>
2020-10-27 14:42:54 -04:00
ee29328abc Merge pull request #8141 from afbjorklund/podman-remote-host-port-master
Add support for host keys for non-22 ports
2020-10-27 13:30:13 -04:00
95f3ec7b08 Merge pull request #8133 from xordspar0/cpu-limit-details
[CI:DOCS] Add more details about how CPU limits work
2020-10-27 13:26:53 -04:00
434de069fe Merge pull request #8134 from xordspar0/cpu.max-permission
[CI:DOCS] Document how to enable CPU limit delegation
2020-10-27 13:23:27 -04:00
eda5a6d069 Merge pull request #8145 from containers/dependabot/go_modules/github.com/containers/common-0.26.2
Bump github.com/containers/common from 0.26.0 to 0.26.3
2020-10-27 13:20:07 -04:00
b8641aec36 Add test cases to cover podman volume
Add test cases to cover below podman volume subcommand:
  create
  ls
  inspect
  rm
  prune

Signed-off-by: Yuhui Jiang <yujiang@redhat.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-10-27 13:16:04 -04:00
cef85763e5 Merge pull request #8164 from Luap99/journal-events
Improve the journal event reading
2020-10-27 17:07:45 +01:00
f393d32e96 Document how to enable CPU limit delegation
Signed-off-by: Jordan Christiansen <xordspar0@gmail.com>
2020-10-27 10:05:43 -05:00
fa73b929e0 Add more details about how CPU limits work
Signed-off-by: Jordan Christiansen <xordspar0@gmail.com>
2020-10-27 09:32:41 -05:00
5d3042c4fb set resources only when specified
when using the compatibility endpoint to create a container, we should only set certain resources when we are provided a value for them or we result in fields with zero values.

Signed-off-by: baude <bbaude@redhat.com>
2020-10-27 09:18:59 -05:00
0f0d857f6c Merge pull request #8151 from vrothberg/fix-8148
image list: check for all errors
2020-10-27 14:29:41 +01:00
692559c8c5 Improve the journal event reading
Fix the AddMatch/SeekTail conflict. This prevents reading
unnecessary journal entries which could cause errors.

Also wrap the sdjournal errors to provide better error messages.

Fixes #8125

Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
2020-10-27 14:10:55 +01:00
2099c86f33 build(deps): bump github.com/containers/common from 0.26.0 to 0.26.3
Bumps [github.com/containers/common](https://github.com/containers/common) from 0.26.0 to 0.26.3.
- [Release notes](https://github.com/containers/common/releases)
- [Commits](containers/common@v0.26.0...v0.26.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-10-27 07:25:23 -04:00
83e54885ff Support hashed hostnames in the known_hosts file
Some systems have "HashKnownHosts yes" in their ssh_config

This causes entries in the ssh known_hosts to be hashed (|)

Signed-off-by: Anders F Björklund <anders.f.bjorklund@gmail.com>
2020-10-27 12:19:44 +01:00
5c0849534d Merge pull request #8094 from rhatdan/cidfile
The cidfile should be created when the container is created
2020-10-27 12:16:28 +01:00
65fabcfce7 image list: check for all errors
For unknown historical reasons, some errors were ignored when listing
images.  I assume that the basic assumption was that if we can properly
list images, we can also successfully compute their sizes which turned
out to be wrong.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-10-27 10:39:09 +01:00
dbbd5987fd Merge pull request #8149 from edsantiago/bats
System tests: cleanup, make more robust
2020-10-27 09:46:00 +01:00
d93d9f60a4 Merge pull request #8144 from vrothberg/auto-update
auto update: mark it as non-experimental
2020-10-27 09:23:59 +01:00
a24341b908 Merge pull request #8155 from edsantiago/pr_title_again
Yet another iteration on PR title plugin
2020-10-27 09:20:39 +01:00
e187423d2a Yet another iteration on PR title plugin
PR #8147 made things worse: it's not valid YAML. This at
least is valid YAML. I have no idea if it yields the
desired result, and we won't even know until it gets
merged, but at least it won't cause fatal syntax errors.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-10-26 13:44:59 -06:00
c93d4be41e System tests: cleanup, make more robust
- run test: preserve --runtime test: use a random executable
  path. And, clean up better.

- run test: "look up correct image name" test: use random
  strings; test both without and with a :tag

- events test: use random label strings, add more filter tests

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-10-26 13:29:15 -06:00
3a62b4d6b7 Merge pull request #8147 from vrothberg/fix-pr-title-action
pr update action: fix errors on master branch
2020-10-26 17:47:53 +01:00
153531d435 pr update action: fix errors on master branch
The action fails on the master branch as the regex does not match.
The error in this scenario is unfortunate and not of much value as
we do not want to change PR titles on the master branch.

To fix it, entirely disable the action on the master branch which
in restrospective may be a better approach as we do not fire off the
action.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-10-26 13:09:20 +01:00
01f642f080 Merge pull request #8138 from vrothberg/main-pr-title-update-action
add GitHub action to add non-main branch to PR title
2020-10-26 06:16:04 -04:00
f9df17a446 Merge pull request #8059 from containers/dependabot/go_modules/github.com/spf13/cobra-1.1.1
Bump github.com/spf13/cobra from 1.1.0 to 1.1.1
2020-10-26 06:02:29 -04:00
32af1be01a The cidfile should be created when the container is created
Currently if you run an interactive session of podman run and
specifiy the --cidfile option, the cidfile will not get created
until the container finishes running.  If you run a detached
container, it will get created right away.  This Patch creates
the cidfile as soon as the container is created.  This could allow
other tools to use the cidefile on all running containers.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-10-26 05:53:26 -04:00
d6b7fdf5d4 auto update: mark it as non-experimental
Auto updates have inititally been marked as experimental which allowed
us to receive initital feedback from the community.  More than half a
year has passed and we are now confident to mark `podman-auto-update`
as stable.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-10-26 10:01:01 +01:00
8f498b52de Merge pull request #8119 from matejvasek/cp-extract-flag-fix
fix: respect "--extract" flag for podman cp
2020-10-26 04:45:02 -04:00
6f6cf87f8f Add support for host keys for non-22 ports
When not using the standard SSH port (22), the port is appended
to the hostname (in brackets) like so: "host" -> "[host]:1234"

Signed-off-by: Anders F Björklund <anders.f.bjorklund@gmail.com>
(cherry picked from commit 8794e8db1ce3088d633911454d6d36c4e939e126)
2020-10-25 16:30:42 +01:00