summaryrefslogtreecommitdiff
path: root/pkg/varlinkapi
Commit message (Collapse)AuthorAge
* Merge pull request #4006 from rhatdan/rootlessOpenShift Merge Robot2019-09-13
|\ | | | | Report errors when trying to pause rootless containers
| * Report errors when trying to pause rootless containersDaniel J Walsh2019-09-13
| | | | | | | | | | | | | | | | If you are running a rootless container on cgroupV1 you can not pause the container. We need to report the proper error if this happens. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | Podman-remote run should wait for exit codeDaniel J Walsh2019-09-12
|/ | | | | | | | This change matches what is happening on the podman local side and should eliminate a race condition. Also exit commands on the server side should start to return to client. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Add function for looking up volumes by partial nameMatthew Heon2019-09-09
| | | | | | | | | | This isn't included in Docker, but seems handy enough. Use the new API for 'volume rm' and 'volume inspect'. Fixes #3891 Signed-off-by: Matthew Heon <matthew.heon@pm.me>
* Return information about mount_program (fuse-overlayfs)Daniel J Walsh2019-09-06
| | | | | | | | | | We want to get podman info to tell us about the version of the mount program to help us diagnose issues users are having. Also if in rootless mode and slirp4netns is installed reveal package info on slirp4netns. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* dont panic when using varlink commit and uppercase image namesbaude2019-08-29
| | | | | | | | | when using an upper case image name for container commit, we observed panics due to a channel closing early. Fixes: #3897 Signed-off-by: baude <bbaude@redhat.com>
* Update varlink doc and codeJhon Honce2019-08-26
| | | | | | | | * Improved error message * Added documentation * Updated messages to include missing data Signed-off-by: Jhon Honce <jhonce@redhat.com>
* clean up after remote buildbaude2019-08-25
| | | | | | | | | | when performing an image build over a varlink connection, we should clean up tmp files that are a result of sending the file to the host and untarring it for the build. Fixes: #3869 Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #3800 from vrothberg/generate-podOpenShift Merge Robot2019-08-22
|\ | | | | generate systemd pod
| * generate systemd: drop support for remote clientsValentin Rothberg2019-08-21
| | | | | | | | | | | | | | | | | | | | | | | | Drop the support for remote clients to generate systemd-service files. The generated files are machine-dependent and hence relate only to the a local machine. Furthermore, a proper service management when using a remote-client is not possible as systemd has no access to a process. Dropping the support will also reduce the risk of making users believe that the generated services are usable in a remote scenario. Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
* | Add --digestfile option to pushTomSweeneyRedHat2019-08-21
|/ | | | | | | | | | Add the digestfile option to the push command so the digest can be stored away in a file when requested by the user. Also have added a debug statement to show the completion of the push. Emulates Buildah's https://github.com/containers/buildah/pull/1799/files Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
* Implement healthcheck for remote clientAshley Cui2019-08-19
| | | | | | Previously unimplemented. Works the same way the local one does, except its remote. Signed-off-by: Ashley Cui <ashleycui16@gmail.com>
* Merge pull request #3709 from mheon/volume_inspectOpenShift Merge Robot2019-08-19
|\ | | | | Change backend code for 'volume inspect'
| * Implement backend for 'volume inspect'Matthew Heon2019-08-02
| | | | | | | | | | | | | | | | | | Begin to separate the internal structures and frontend for inspect on volumes. We can't rely on keeping internal data structures for external presentation - separating presentation and internal data format is good practice. Signed-off-by: Matthew Heon <matthew.heon@pm.me>
* | Merge pull request #3617 from QiWang19/create_pullOpenShift Merge Robot2019-08-17
|\ \ | | | | | | add --pull flag for podman create&run
| * | add --pull flag for podman create&runQi Wang2019-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Requirement from https://github.com/containers/libpod/issues/3575#issuecomment-512238393 Added --pull for podman create and pull to match the newly added flag in docker CLI. `missing`: default value, podman will pull the image if it does not exist in the local. `always`: podman will always pull the image. `never`: podman will never pull the image. Signed-off-by: Qi Wang <qiwan@redhat.com>
* | | varlink endpoint for containerstats requires rootbaude2019-08-12
|/ / | | | | | | | | | | | | | | | | | | | | obtaining containerstats requires the use of cgroups. at present, rootless users do not have privileges to create cgroups. add an error message that catches this for the varlink endpoint and return a proper error. Fixes: #3749 Signed-off-by: baude <bbaude@redhat.com>
* | Merge pull request #3716 from baude/varlinkfixes2OpenShift Merge Robot2019-08-05
|\ \ | | | | | | various fixes for varlink endpoints
| * | various fixes for varlink endpointsbaude2019-08-03
| |/ | | | | | | | | | | | | | | | | | | | | when using build, require a "more" connection to get logs. when pulling a non-existent image, do not crash varlink connection. Fixes: #3714 Fixes: #3715 Signed-off-by: baude <bbaude@redhat.com>
* / add eventlogger to infobaude2019-08-02
|/ | | | | | | to help with future debugging, we now display the type of event logger being used inside podman info -> host. Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #3341 from rhatdan/exitOpenShift Merge Robot2019-08-01
|\ | | | | Add new exit codes to rm & rmi for running containers & dependencies
| * Add new exit codes to rm & rmi for running containers & dependenciesDaniel J Walsh2019-08-01
| | | | | | | | | | | | | | | | | | | | | | | | This enables programs and scripts wrapping the podman command to handle 'podman rm' and 'podman rmi' failures caused by paused or running containers or due to images having other child images or dependent containers. These errors are common enough that it makes sense to have a more machine readable way of detecting them than parsing the standard error output. Signed-off-by: Ondrej Zoder <ozoder@redhat.com> Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | Vendor in buildah 1.9.2Daniel J Walsh2019-07-30
|/ | | | Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* refactor to reduce duplicated error parsingPeter Hunt2019-07-23
| | | | Signed-off-by: Peter Hunt <pehunt@redhat.com>
* remove debug printsPeter Hunt2019-07-23
| | | | Signed-off-by: Peter Hunt <pehunt@redhat.com>
* remove unnecessary conversionsPeter Hunt2019-07-23
| | | | Signed-off-by: Peter Hunt <pehunt@redhat.com>
* add detach keys support for remotePeter Hunt2019-07-23
| | | | Signed-off-by: Peter Hunt <pehunt@redhat.com>
* move editing of exitCode to runtimePeter Hunt2019-07-23
| | | | | | | | | There's no way to get the error if we successfully get an exit code (as it's just printed to stderr instead). instead of relying on the error to be passed to podman, and edit based on the error code, process it on the varlink side instead Also move error codes to define package Signed-off-by: Peter Hunt <pehunt@redhat.com>
* Update e2e tests for remote execPeter Hunt2019-07-23
| | | | | | | including changing -l to the container id and separating a case of setting the env that remote can't handle Signed-off-by: Peter Hunt <pehunt@redhat.com>
* Finish up remote exec implementationPeter Hunt2019-07-23
| | | | Signed-off-by: Peter Hunt <pehunt@redhat.com>
* Implement conmon execPeter Hunt2019-07-22
| | | | | | | | | | | | | | | | | | | | | | This includes: Implement exec -i and fix some typos in description of -i docs pass failed runtime status to caller Add resize handling for a terminal connection Customize exec systemd-cgroup slice fix healthcheck fix top add --detach-keys Implement podman-remote exec (jhonce) * Cleanup some orphaned code (jhonce) adapt remote exec for conmon exec (pehunt) Fix healthcheck and exec to match docs Introduce two new OCIRuntime errors to more comprehensively describe situations in which the runtime can error Use these different errors in branching for exit code in healthcheck and exec Set conmon to use new api version Signed-off-by: Jhon Honce <jhonce@redhat.com> Signed-off-by: Peter Hunt <pehunt@redhat.com>
* Merge pull request #3562 from baude/golangcilint3OpenShift Merge Robot2019-07-22
|\ | | | | golangci-lint round #3
| * golangci-lint round #3baude2019-07-21
| | | | | | | | | | | | | | this is the third round of preparing to use the golangci-lint on our code base. Signed-off-by: baude <bbaude@redhat.com>
* | Remove debug messageDaniel J Walsh2019-07-20
|/ | | | Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Add support for listing read/only and read/write imagesDaniel J Walsh2019-07-19
| | | | | | | When removing --all images prune images only attempt to remove read/write images, ignore read/only images Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Merge pull request #3584 from QiWang19/pssizeOpenShift Merge Robot2019-07-18
|\ | | | | podman-remote make --size optional in ps
| * podman-remote make --size optional in psQi Wang2019-07-18
| | | | | | | | | | | | Close #3578 Add `size` field to PsOpts in podman remote to receive size as an option. Signed-off-by: Qi Wang <qiwan@redhat.com>
* | Move the HostConfig portion of Inspect inside libpodMatthew Heon2019-07-17
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we first began writing Podman, we ran into a major issue when implementing Inspect. Libpod deliberately does not tie its internal data structures to Docker, and stores most information about containers encoded within the OCI spec. However, Podman must present a CLI compatible with Docker, which means it must expose all the information in 'docker inspect' - most of which is not contained in the OCI spec or libpod's Config struct. Our solution at the time was the create artifact. We JSON'd the complete CreateConfig (a parsed form of the CLI arguments to 'podman run') and stored it with the container, restoring it when we needed to run commands that required the extra info. Over the past month, I've been looking more at Inspect, and refactored large portions of it into Libpod - generating them from what we know about the OCI config and libpod's (now much expanded, versus previously) container configuration. This path comes close to completing the process, moving the last part of inspect into libpod and removing the need for the create artifact. This improves libpod's compatability with non-Podman containers. We no longer require an arbitrarily-formatted JSON blob to be present to run inspect. Fixes: #3500 Signed-off-by: Matthew Heon <matthew.heon@pm.me>
* Fix the double replySendFile()Harald Hoyer2019-07-12
| | | | Signed-off-by: Harald Hoyer <harald@redhat.com>
* account for varlink calls that dont use morebaude2019-07-10
| | | | | | | | | | | the commit and pull varlink endpoints were not working correctly when 'more' was not being specified. Fixes: #3317 Fixes: #3318 Fixes: #3526 Signed-off-by: baude <bbaude@redhat.com>
* libpod removal from main (phase 2)baude2019-06-27
| | | | | | this is phase 2 for the removal of libpod from main. Signed-off-by: baude <bbaude@redhat.com>
* remove libpod from mainbaude2019-06-25
| | | | | | | | | | | | | the compilation demands of having libpod in main is a burden for the remote client compilations. to combat this, we should move the use of libpod structs, vars, constants, and functions into the adapter code where it will only be compiled by the local client. this should result in cleaner code organization and smaller binaries. it should also help if we ever need to compile the remote client on non-Linux operating systems natively (not cross-compiled). Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #3225 from haraldh/virtwriterOpenShift Merge Robot2019-06-04
|\ | | | | pkg/varlinkapi/virtwriter/virtwriter.go: simplify func Reader
| * pkg/varlinkapi/virtwriter/virtwriter.go: simplify func ReaderHarald Hoyer2019-06-03
| | | | | | | | Signed-off-by: Harald Hoyer <harald@redhat.com>
* | Merge pull request #3081 from baude/remotecommitOpenShift Merge Robot2019-06-03
|\ \ | |/ |/| podman remote-client commit
| * podman remote-client commitbaude2019-05-30
| | | | | | | | | | | | | | add the ability to commit a container to an image using the remote client. Signed-off-by: baude <bbaude@redhat.com>
* | Fix the varlink upgraded callsHarald Hoyer2019-05-29
|/ | | | | | | | Although an upgraded call is requested, the server has to send at least one reply (can be an error) and the client has to check the reply, before assuming an upgraded connection. Signed-off-by: Harald Hoyer <harald@redhat.com>
* Fixup FlagsDaniel J Walsh2019-05-20
| | | | | | | | Mark hidden all references to signature-policy Default all uses of --authfile Add --authfile support to podman run and podman create. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Revert "Add VarlinkCall.RequiresUpgrade() type and method"Matthew Heon2019-05-16
| | | | | | | | This reverts commit bd3154fcf6a48b37cfde5d9b1226900cd863c0d9. Commit in question may be breaking upstream CI. Signed-off-by: Matthew Heon <mheon@redhat.com>
* Add VarlinkCall.RequiresUpgrade() type and methodJhon Honce2019-05-14
| | | | | | | | | | Type varlinkapi.VarlinkCall currently only used as receiver for RequiresUpgrade() future helpers could be added to this type. RequiresUpgrade() verifies caller has given correct options to the call for the given operation. Signed-off-by: Jhon Honce <jhonce@redhat.com>