3212 Commits

Author SHA1 Message Date
0d3eaca28a SearchImages: extend API with filter parameter
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2019-02-20 10:25:25 +01:00
87c9f4cc22 podman-search: refactor code to libpod/image/search.go
Refactor the image-search logic from cmd/podman/search.go to
libpod/image/search.go and update podman-search and the Varlink API to
use it.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2019-02-20 10:25:25 +01:00
b5c0d15683 podman-search: run in parallel
Spin up a goroutine for each registry to make podman-search run in
parallel.  This has considerable speed improvements.  For instance, a
`podman search ruby` drops from 11 to 2 seconds when using the following
search registries:

```toml
[registries.search]
registries = ['docker.io', 'registry.fedoraproject.org', 'quay.io',
              'registry.access.redhat.com', 'registry.centos.org']
```

The number of parallel goroutines is limited to 6 to play nice with
local resources and the registries.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2019-02-20 10:25:25 +01:00
5642472c49 Ensure that userns is created for stopped rootless pods
Signed-off-by: Matthew Heon <mheon@redhat.com>
2019-02-19 17:16:43 -05:00
3b88c73507 Merge pull request #2373 from mheon/pod_has_no_arguments
Podman pod create now errors on receiving CLI args
2019-02-19 23:06:59 +01:00
91ae38092b Podman pod create now errors on receiving CLI args
It has never accepted arguments, so we should error when passed
args we will never use.

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2019-02-19 15:03:56 -05:00
82ae36c157 Merge pull request #2363 from TomSweeneyRedHat/dev/tsweeney/cobraex5
Fifth chunk of Cobra Examples
2019-02-19 19:48:05 +01:00
10ffa3ff82 Merge pull request #2348 from baude/remotepullverbose
podman-remote pull
2019-02-19 17:54:36 +01:00
8f40c4e6b4 podman-remote pull
Add status for remote users and podman remote-client pull.

Signed-off-by: baude <bbaude@redhat.com>
2019-02-19 10:13:07 -06:00
e92f7ca7dd Merge pull request #2366 from haircommander/dont-start-started-deps
Don't start running dependencies
2019-02-19 16:43:27 +01:00
a784071902 Don't start running dependencies
Before, a container being run or started in a pod always restarted the infra container. This was because we didn't take running dependencies into account. Fix this by filtering for dependencies in the running state.

Signed-off-by: Peter Hunt <pehunt@redhat.com>
2019-02-19 09:28:58 -05:00
675a202a1b Fifth chunk of Cobra Examples
Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>

The fifth and final chunk of examples for the Cobra
examples in the CLI help output.

Also includes a few man page touchups.

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2019-02-18 19:37:09 -05:00
228d1cbcd3 Merge pull request #2361 from TomSweeneyRedHat/dev/tsweeney/cobraex4
Add 4th chunk of Cobra Examples
2019-02-18 22:14:57 +01:00
c9b13133cd Merge pull request #1692 from sjug/opentracing_clean
OpenTracing First Impl
2019-02-18 22:01:14 +01:00
64853710e8 Add 4th chunk of Cobra Examples
Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>

Adds the 4th chunk of Cobra Examples to the CLI help.
One more chunk of 10 to complete.

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2019-02-18 15:18:42 -05:00
7141f97270 OpenTracing support added to start, stop, run, create, pull, and ps
Drop context.Context field from cli.Context

Signed-off-by: Sebastian Jug <sejug@redhat.com>
2019-02-18 09:57:08 -05:00
e738ef1622 Merge pull request #2354 from rhatdan/varlink
Add registry name to fields returned by varlink image search
2019-02-18 13:32:54 +01:00
f2139a6517 Merge pull request #2359 from nitkon/master
packer: Make Makefile host arch sensitive
2019-02-18 12:54:43 +01:00
383e573299 packer: Make Makefile host arch sensitive
`make localunit` fails on non-amd64 archs
as it unzips packer_1.3.2_linux_amd64.zip
irrespective of host arch its running on.

Signed-off-by: Nitesh Konkar <niteshkonkar@in.ibm.com>
2019-02-18 10:23:57 +05:30
3f32eae56f Merge pull request #2357 from TomSweeneyRedHat/dev/tsweeney/cobrahelp3
Add 3rd chunk of Cobra examples
2019-02-17 22:44:04 +01:00
6aaf8d39a9 Merge pull request #2295 from haircommander/recursive-start
Recursively start a pod if a container is run in it
2019-02-17 21:04:33 +01:00
b62c0e703d Add 3rd chunk of Cobra examples
Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>

Adds the third chunk of Cobra examples to the cli help.
As were putting together a release tomorrow, tried to
hit the heavy commands with this PR.

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2019-02-17 13:49:05 -05:00
a99f4924d9 Merge pull request #2340 from QiWang19/login_lying
Fix `podman login` lying problem
2019-02-17 13:44:45 +01:00
1cb16bd24b Merge pull request #2341 from TomSweeneyRedHat/dev/tsweeney/helpexamples2
Second chunk of Cobra help
2019-02-16 17:31:51 +01:00
81804fc464 pod infra container is started before a container in a pod is run, started, or attached.
Prior, a pod would have to be started immediately when created, leading to confusion about what a pod state should be immediately after creation. The problem was podman run --pod ... would error out if the infra container wasn't started (as it is a dependency). Fix this by allowing for recursive start, where each of the container's dependencies are started prior to the new container. This is only applied to the case where a new container is attached to a pod.

Also rework container_api Start, StartAndAttach, and Init functions, as there was some duplicated code, which made addressing the problem easier to fix.

Signed-off-by: Peter Hunt <pehunt@redhat.com>
2019-02-15 16:39:24 -05:00
0a521e139f Merge pull request #2335 from mheon/enable_detach_rm
Enable --rm with --detach
2019-02-15 22:05:13 +01:00
b75dcd4458 Add registry name to fields returned by varlink image search
Cockpit team wants to list the registry name where the image was
found.

Also fix up SearchImages code to check if the user specified a registry
in his call to use that rather then all the registries, This matches
podman search command.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2019-02-15 15:30:09 -05:00
72b91eb87f Second chunk of Cobra help
Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>

Adds examples to Cobra help for a second chunk of commands.

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2019-02-15 14:38:46 -05:00
9c1b08fd79 Merge pull request #2353 from giuseppe/honor-storage-opt
podman: honor --storage-opt again
2019-02-15 20:22:06 +01:00
de146b0a2d podman: honor --storage-opt again
possibly a regression after we moved to Cobra

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-02-15 19:43:03 +01:00
40c6d5c98c Merge pull request #2188 from TomSweeneyRedHat/dev/tsweeney/pullall
Add --all-tags to pull command
2019-02-15 14:45:03 +01:00
5a0a1144c5 Merge pull request #2346 from giuseppe/fix-runtime-lookup
libpod.conf: add backward compatibility for runtime_path
2019-02-15 14:21:43 +01:00
7899b738f4 docs: mention the new OCI runtime configuration
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-02-15 13:04:23 +01:00
8aa9b85fa7 libpod: honor runtime_path from libpod.conf
Add backward compatibility for `runtime_path` that was used by older
versions of Podman.

The issue was introduced with: 650cf122e1b33f4d8f4426ee1cc1a4bf00c14798

If `runtime_path` is specified, it overrides any other configuration
and a warning is printed.

It should be considered deprecated and will be removed in future.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-02-15 11:41:17 +01:00
71782812fe rootless: open the correct file
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2019-02-15 10:53:50 +01:00
d512c4d255 Merge pull request #2305 from rhatdan/tlsverify
Add tlsVerify bool to SearchImage for varlink
2019-02-15 10:50:36 +01:00
81ace5caac Merge pull request #2333 from TomSweeneyRedHat/dev/tsweeney/helpexamples
Add examples for Cobra
2019-02-15 00:07:34 +01:00
c90d3177ad Fix podman login lying problem
Signed-off-by: Qi Wang <qiwan@redhat.com>
2019-02-14 17:00:24 -05:00
ae8cc41295 Merge pull request #2332 from baude/remotevolumeprune
volume prune
2019-02-14 22:52:03 +01:00
1a9128d1e4 Merge pull request #2320 from QiWang19/stdinPW
--password-stdin flag in `podman login`
2019-02-14 22:31:58 +01:00
18bf883eeb Merge pull request #2151 from QiWang19/cp
'podman cp' copy between host and container
2019-02-14 22:31:52 +01:00
1b352ff62a Merge pull request #2298 from mtrmac/multiple-manifests
Vendor in latest c/storage and c/image
2019-02-14 22:05:39 +01:00
2e6fff1f5e Fix error code retrieval for podman start --attach
When we start a container with 'podman run' and it exits and is
removed before we get the code, we grab its exit code from the
Conmon exit file. Podman start --attach wants to do the same, but
was missing the logic. Fix that here.

Also, remove some --rm handling leftover in start. Don't need it
anymore, we have the cleanup process now.

Signed-off-by: Matthew Heon <mheon@redhat.com>
2019-02-14 15:54:34 -05:00
b5653a7f36 Enable --rm with --detach
We can now safely remove detached containers as --rm handling has
moved into the cleanup process.

Signed-off-by: Matthew Heon <mheon@redhat.com>
2019-02-14 15:53:53 -05:00
8ec9eb0a76 Merge pull request #2229 from rhatdan/volumes
Fix volume handling in podman
2019-02-14 21:45:58 +01:00
a7a691809a Add examples for Cobra
Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>

First pass of entries for the Examples listed in the Cobra
Help.  Will add others in following PR's.
2019-02-14 15:03:11 -05:00
5f7d4ee73f Add tlsVerify bool to SearchImage for varlink
Cockpit wants to be able to search images on systems without
tlsverify turned on.

tlsverify should be an optional parameter, if not set then we default
to the system defaults defined in /etc/containers/registries.conf.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2019-02-14 14:31:20 -05:00
52df1fa7e0 Fix volume handling in podman
iFix builtin volumes to work with podman volume

Currently builtin volumes are not recored in podman volumes when
they are created automatically. This patch fixes this.

Remove container volumes when requested

Currently the --volume option on podman remove does nothing.
This will implement the changes needed to remove the volumes
if the user requests it.

When removing a volume make sure that no container uses the volume.

Signed-off-by: Daniel J Walsh dwalsh@redhat.com
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2019-02-14 13:21:52 -05:00
dd82acd8ba Merge pull request #2336 from baude/addbuildtomain
add build to main and as subcommand to image
2019-02-14 19:16:03 +01:00
5be818e715 enable podman-remote volume prune
allow users to remotely prune volumes.

this is the last volume command for remote enablement.  as such,
the volume commands are being folded back into main because they
are supported for both local and remote clients.

also, enable all volume tests that do not use containers
as containers are not enabled for the remote client yet.

Signed-off-by: baude <bbaude@redhat.com>
2019-02-14 10:55:05 -06:00