summaryrefslogtreecommitdiff
path: root/libpod
Commit message (Collapse)AuthorAge
* Merge pull request #2281 from rhatdan/deleteContainerOpenShift Merge Robot2019-02-11
|\ | | | | Remove container from storage on --force
| * Remove container from storage on --forceDaniel J Walsh2019-02-09
| | | | | | | | | | | | | | | | | | Currently we can get into a state where a container exists in storage but does not exist in libpod. If the user forces a removal of this container, then we should remove it from storage even if the container is owned by another tool. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | lock and sync container before checking mountpointbaude2019-02-11
| | | | | | | | | | | | | | | | | | when checking for a container's mountpoint, you must lock and sync the container or the result may be "". Fixes: #2304 Signed-off-by: baude <bbaude@redhat.com>
* | oci: do not set XDG_RUNTIME_DIR twiceGiuseppe Scrivano2019-02-11
|/ | | | | | we are doing it few lines above. Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* Migrate to cobra CLIbaude2019-02-08
| | | | | | | | We intend to migrate to the cobra cli from urfave/cli because the project is more well maintained. There are also some technical reasons as well which extend into our remote client work. Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #2252 from rhatdan/systemOpenShift Merge Robot2019-02-06
|\ | | | | Add podman system prune and info commands
| * Add podman system prune and info commandsDaniel J Walsh2019-02-05
| | | | | | | | | | | | | | | | | | We are missing the equivalence of the docker system commands This patch set adds `podman system prune` and `podman system info` Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | Merge pull request #2273 from mheon/preserve_exited_stateOpenShift Merge Robot2019-02-06
|\ \ | |/ |/| Preserve exited state across reboot
| * Preserve exited state across rebootMatthew Heon2019-02-05
| | | | | | | | | | | | | | | | | | | | | | | | | | Instead of unconditionally resetting to ContainerStateConfigured after a reboot, allow containers in the Exited state to remain there, preserving their exit code in podman ps after a reboot. This does not affect the ability to use and restart containers after a reboot, as the Exited state can be used (mostly) interchangeably with Configured for starting and managing containers. Signed-off-by: Matthew Heon <matthew.heon@pm.me>
* | podman-remote import|exportbaude2019-02-05
|/ | | | | | | | addition of import and export for the podman-remote client. This includes the ability to send and receive files between the remote-client and the "podman" host using an upgraded varlink connection. Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #2196 from baude/toolboxDaniel J Walsh2019-02-05
|\ | | | | Changes to container runlabel for toolbox project
| * Changes to container runlabel for toolbox projectbaude2019-01-30
| | | | | | | | | | | | | | | | | | | | The toolbox project would benefit from a few changes to more closely resembe the original atomic cli project. Changes made are: * only pull image for container runlabel if the label exists in the image * if a container image does not have the desired label, exit with non-zero Signed-off-by: baude <bbaude@redhat.com>
* | rootless: copy some settings from the global configurationGiuseppe Scrivano2019-02-05
| | | | | | | | | | | | | | | | | | if some paths are overriden in the global configuration file, be sure that rootless podman honors them. Closes: https://github.com/containers/libpod/issues/2174 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* | libpod/image: Use RepoDigests() in Inspect()W. Trevor King2019-01-31
|/ | | | | | | To get the more-robust handling from 0f6535cf (libpod/image: Use ParseNormalizedNamed in RepoDigests, 2019-01-08, #2106) here too. Signed-off-by: W. Trevor King <wking@tremily.us>
* podman image prune -- implement all flagbaude2019-01-29
| | | | | | | | | | | we now, by default, only prune dangling images. if --all is passed, we prune dangling images AND images that do not have an associated containers. also went ahead and enabled the podman-remote image prune side of things. Fixes: #2192 Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #2069 from mheon/warn_on_overriding_driverOpenShift Merge Robot2019-01-23
|\ | | | | Warn on overriding user-specified storage driver w/ DB
| * Warn on overriding user-specified storage driver w/ DBMatthew Heon2019-01-02
| | | | | | | | | | | | | | | | Overriding storage.conf is not intuitive behavior, so pop up an error message when it happens, so people know that bad things are happening. Signed-off-by: Matthew Heon <matthew.heon@pm.me>
* | Merge pull request #2199 from baude/remoteversionOpenShift Merge Robot2019-01-22
|\ \ | | | | | | enable podman-remote version
| * | enable podman-remote versionbaude2019-01-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | initial enablement of podman-remote version. includes add a APIVersion const that will allow us to check compatibility between host/client when connections are made. also added client related information to podman info. Signed-off-by: baude <bbaude@redhat.com>
* | | Show a better error message when podman info fails during a refreshRyan Gonzalez2019-01-21
|/ / | | | | | | Signed-off-by: Ryan Gonzalez <rymg19@gmail.com>
* | Merge pull request #2187 from rhatdan/selinuxOpenShift Merge Robot2019-01-21
|\ \ | | | | | | Vendor in latest opencontainers/selinux
| * | Vendor in latest opencontainers/selinuxDaniel J Walsh2019-01-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will now verify labels passed in by the user. Will also prevent users from accidently relabeling their homedir. podman run -ti -v ~/home/user:Z fedora sh Is not a good idea. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | | Merge pull request #2142 from giuseppe/expose-portsOpenShift Merge Robot2019-01-20
|\ \ \ | | | | | | | | rootless: support port redirection from the host
| * | | rootless: support port redirection from the hostGiuseppe Scrivano2019-01-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | add support for ports redirection from the host. It needs slirp4netns v0.3.0-alpha.1. Closes: https://github.com/containers/libpod/issues/2081 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* | | | podman-remote inspectbaude2019-01-18
| |/ / |/| | | | | | | | | | | | | | base enablement of the inspect command. Signed-off-by: baude <bbaude@redhat.com>
* | | Do not unmarshal into c.config.SpecMatthew Heon2019-01-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We try to keep c.config immutable, but Go doesn't really agree with me that things other than strings and ints can be immutable, so occasionally things like this slip through. When unmarshalling the OCI spec from disk, do it into a separate struct, to ensure we don't make lasting modifications to the spec in the Container struct (which could affect container restart). Signed-off-by: Matthew Heon <matthew.heon@pm.me>
* | | Merge pull request #2149 from afbjorklund/bridgeOpenShift Merge Robot2019-01-18
|\ \ \ | | | | | | | | Add bridge support, for the varlink connection
| * | | Add bridge support, for the varlink connectionAnders F Björklund2019-01-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Read the $PODMAN_VARLINK_BRIDGE environment variable (normally looks like: "ssh user@host varlink bridge") Also respect $PODMAN_VARLINK_ADDRESS as an override, if using a different podman socket than the default. Signed-off-by: Anders F Björklund <anders.f.bjorklund@gmail.com>
* | | | Merge pull request #2169 from mheon/ensure_wait_doesnot_hangOpenShift Merge Robot2019-01-16
|\ \ \ \ | | | | | | | | | | Ensure that wait exits on state transition
| * | | | Ensure that wait exits on state transitionMatthew Heon2019-01-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When waiting for a container, there is a long interval between status checks - plenty long enough for the container in question to start, then subsequently be cleaned up and returned to Created state to be restarted. As such, we can't wait on container state to go to Stopped or Exited - anything that is not Running or Paused indicates the container is dead. Signed-off-by: Matthew Heon <matthew.heon@pm.me>
* | | | | Merge pull request #2079 from giuseppe/multiple-runtimesOpenShift Merge Robot2019-01-16
|\ \ \ \ \ | | | | | | | | | | | | oci: allow to define multiple OCI runtimes
| * | | | | config: store the runtime used to create each containerGiuseppe Scrivano2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
| * | | | | oci: allow to define multiple OCI runtimesGiuseppe Scrivano2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | we can define multiple OCI runtimes that can be chosen with --runtime. in libpod.conf is possible to specify them with: [runtimes] foo = [ "/usr/bin/foo", "/usr/sbin/foo", ] bar = [ "/usr/bin/foo", "/usr/sbin/foo", ] If the argument to --runtime is an absolute path then it is used directly without any lookup in the configuration. Closes: https://github.com/containers/libpod/issues/1750 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
| * | | | | libpod: allow multiple oci runtimesVincent Batts2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This deprecates the libpod.conf variable of `runtime_path=`, and now has `runtimes=`, like a map for naming the runtime, preparing for a `--runtime` flag to `podman run` (i.e. runc, kata, etc.) Reference: https://github.com/containers/libpod/issues/1750 Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
* | | | | | Embed runtime struct in super localRuntimebaude2019-01-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We clean up the code by eliminating stuttering references when we embed the runtime struct into localRuntime. Makes for less change in the future as well. ++ jhonce Signed-off-by: baude <bbaude@redhat.com>
* | | | | | Collaberative podman-remote container existsbaude2019-01-15
| |/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Began frameout of container super structs for adapted methods. This allows for the use of container exists. Signed-off-by: baude <bbaude@redhat.com>
* | | | | add support for podman-remote historybaude2019-01-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | this adds support to get the history for an image and its layers using podman-remote. Signed-off-by: baude <bbaude@redhat.com>
* | | | | podman remote client -- add rmibaude2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | allow the podman remote client to delete images Signed-off-by: baude <bbaude@redhat.com>
* | | | | Run integrations test with remote-clientbaude2019-01-14
| |_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the ability to run the integration (ginkgo) suite using the remote client. Only the images_test.go file is run right now; all the rest are isolated with a // +build !remotelinux. As more content is developed for the remote client, we can unblock the files and just block single tests as needed. Signed-off-by: baude <bbaude@redhat.com>
* | | | Remove imageParts.{isTagged,registry,name,tag}Miloslav Trmač2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Finally, these members no longer have any users. Future users should usually call referenceWithRegistry / normalizedReference, and work with the returned value, instead of reintroducing these variables. Similarly, direct uses of unnormalizedRef should be rare (only for cases where the registry and/or path truly does not matter). Should not change behavior. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
* | | | Clarify comments about isRegistry a bit.Miloslav Trmač2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | Should not change behavior. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
* | | | Use imageParts.unnormalizedRef in GetImageBaseNameMiloslav Trmač2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ... to remove the last user of imageParts.name. Should not change behavior. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
* | | | FIXME? Introduce imageParts.suspiciousRefNameTagValuesForSearchMiloslav Trmač2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Image.MatchRepoTag and findImageInRepoTags do some kind of heuristic search; the motivation and design of both, and how they should deal with digests, is not obvious to me. Instead of figuring that out now, just factor it out into a scary-named method and leave the "tag" value (with its "latest"/"none" value) alone. Similarly, the .registry and .name fields should typically not be used; users should use either hasRegistry or normalized reference types; so, isolate the difficult-to-understand search code, and computation of these values, into this new search-specific helper. Should not change behavior. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
* | | | Use imageParts.referenceWithRegistry in Image.getLocalImageMiloslav Trmač2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ... to make sure everything uses the same code path. Should not change behavior. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
* | | | Don't try to look up local images with an explicit :latest suffixMiloslav Trmač2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | imageruntime.getImage, through ParseStoreReference, already uses reference.TagNameOnly on the input, so this extra lookup is completely redundant to the lookup that has already happened. Should not change behavior, apart from speeding up the code a bit. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
* | | | Return a reference.Named from normalizedTagMiloslav Trmač2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of returning a string, return a native value and convert it into the string in the caller, to make it that small bit more common to use reference types. Should not change behavior. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
* | | | Use reference.TagNameOnly instead of manually adding imageParts.tag in ↵Miloslav Trmač2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | normalizeTag Again, rely on the official API, instead of the suprising "suspiciousTagValueForSearch" value (set to :latest on untagged images, and :none on digested ones!) CHANGES BEHAVIOR, but the previous output of normalization of digested values was not even syntatically valid, so this can't really be worse. Still, maybe we should refuse to tag with digested references in the first place. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
* | | | Use imageParts.normalizedReference in normalizeTagMiloslav Trmač2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is another step to using reference values instead of strings here. CHANGES BEHAVIOR: docker.io/busybox is now normalized to docker.io/library/busybox. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
* | | | Add imageParts.normalizedReference()Miloslav Trmač2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will be used in normalizeTag to work with references instead of strings. Not used anywhere yet, should not change behavior. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
* | | | Use imageparts.referenceWithRegistry in normalizeTagMiloslav Trmač2019-01-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ... instead of open-coding something similar. Eventually we will use the reference type further in here. Should not change behavior. Signed-off-by: Miloslav Trmač <mitr@redhat.com>