summaryrefslogtreecommitdiff
path: root/pkg/api
Commit message (Collapse)AuthorAge
* Match swagger to "as built" outputJhon Honce2021-05-21
| | | | | | | | | | | * Remove all Types no longer referenced, they were never used A future API breaking version of Podman API, may restore these Types and push formatting into presentation layer vs. server. Fixes #9578 Signed-off-by: Jhon Honce <jhonce@redhat.com>
* Downgrade API service routing table loggingJhon Honce2021-05-20
| | | | | | | | | | | [NO TESTS NEEDED] * Log the routing table output at Trace vs. Debug level. Reduce noise in debugging output. * Tweak SDNotify message to report Warn when it fails. Previously failures were silent. Signed-off-by: Jhon Honce <jhonce@redhat.com>
* Merge pull request #10371 from matejvasek/fix-wait-compatOpenShift Merge Robot2021-05-19
|\ | | | | fix: response of containers wait endpoint
| * fix: response body of containers wait endpointMatej Vasek2021-05-18
| | | | | | | | | | | | | | The `Error` part of response must be nil (or omitted) if no error occurred. Before this commit a zero value for the struct was returned. Signed-off-by: Matej Vasek <mvasek@redhat.com>
* | Fix formatting and indentation in network http api docsJakub Guzik2021-05-17
|/ | | | Signed-off-by: Jakub Guzik <jakubmguzik@gmail.com>
* Merge pull request #10271 from matejvasek/fix-wait-next-exitOpenShift Merge Robot2021-05-10
|\ | | | | fix: improved "containers/{name}/wait" endpoint
| * fix: improved "containers/{name}/wait" endpointMatej Vasek2021-05-10
| | | | | | | | | | | | | | | | Using event API to detect changes to container instead of polling. Polling was unreliable, sometime change of a state might have been missed. Signed-off-by: Matej Vasek <mvasek@redhat.com>
* | Add client disconnect to build handler loopJhon Honce2021-05-10
| | | | | | | | | | | | | | | | | | [NO TESTS NEEDED] In process of debugging added request channel check and logging message to build loop. Unable to recreate build drop issue after this. 68k build iterations without fail. Signed-off-by: Jhon Honce <jhonce@redhat.com>
* | fix: use UTC Time Stamps in response JSONMatej Vasek2021-05-10
| | | | | | | | Signed-off-by: Matej Vasek <mvasek@redhat.com>
* | Merge pull request #10265 from matejvasek/fix-get-multiple-imgs-compatOpenShift Merge Robot2021-05-08
|\ \ | | | | | | fix: compat API "images/get" for multiple images
| * | fix: compat API "images/get" for multiple imagesMatej Vasek2021-05-07
| |/ | | | | | | Signed-off-by: Matej Vasek <mvasek@redhat.com>
* | Merge pull request #10259 from rhatdan/pullOpenShift Merge Robot2021-05-07
|\ \ | |/ |/| Report Download complete in Compatibility mode
| * Report Download complete in Compatibility modeDaniel J Walsh2021-05-07
| | | | | | | | | | | | | | | | Fixes: https://github.com/containers/podman/issues/10258 [NO TESTS NEEDED] Difficult to create tests for this. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | fix pre review requestMatej Vasek2021-05-06
| | | | | | | | Signed-off-by: Matej Vasek <mvasek@redhat.com>
* | fix: docker APIv2 `images/get`Matej Vasek2021-05-05
|/ | | | Signed-off-by: Matej Vasek <mvasek@redhat.com>
* Merge pull request #10208 from Luap99/play-kube-macOpenShift Merge Robot2021-05-05
|\ | | | | add --mac-address to podman play kube
| * add --mac-address to podman play kubePaul Holzinger2021-05-04
| | | | | | | | | | | | | | | | | | | | Add a new --mac-address flag to podman play kube. This is used to specify a static MAC address which should be used for the pod. This option can be specified several times because play kube can create more than one pod. Fixes #9731 Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
* | migrate Podman to containers/common/libimageValentin Rothberg2021-05-05
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Migrate the Podman code base over to `common/libimage` which replaces `libpod/image` and a lot of glue code entirely. Note that I tried to leave bread crumbs for changed tests. Miscellaneous changes: * Some errors yield different messages which required to alter some tests. * I fixed some pre-existing issues in the code. Others were marked as `//TODO`s to prevent the PR from exploding. * The `NamesHistory` of an image is returned as is from the storage. Previously, we did some filtering which I think is undesirable. Instead we should return the data as stored in the storage. * Touched handlers use the ABI interfaces where possible. * Local image resolution: previously Podman would match "foo" on "myfoo". This behaviour has been changed and Podman will now only match on repository boundaries such that "foo" would match "my/foo" but not "myfoo". I consider the old behaviour to be a bug, at the very least an exotic corner case. * Futhermore, "foo:none" does *not* resolve to a local image "foo" without tag anymore. It's a hill I am (almost) willing to die on. * `image prune` prints the IDs of pruned images. Previously, in some cases, the names were printed instead. The API clearly states ID, so we should stick to it. * Compat endpoint image removal with _force_ deletes the entire not only the specified tag. Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
* compat api: Networks must be empty instead of nullPaul Holzinger2021-05-04
| | | | | | | | | The compat endpoint for container inspect must return {} instead of null for NetworkSettings.Networks. Fixes #9837 Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
* Docker returns 'die' status rather then 'died' statusDaniel J Walsh2021-04-28
| | | | | | | | | | | | In order to be more compatible with Docker, we should return a container die status rather then a "container died", Too late to change this for Podman. Partially fixes: https://github.com/containers/podman/issues/10168 [NO TESTS NEEDED] No easy way to test this. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Allow docker volume create API to pass without nameDaniel J Walsh2021-04-27
| | | | | | | | | The Docker API does not require Volume name to be specified when creating a volume. Fixes: https://github.com/containers/podman/issues/9803 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Fix removal race condition in ListContainersSoMuchForSubtlety2021-04-23
| | | | | | | | | | | It is possible that a container is removed between fetching the initial list of containers and the second access during conversion. Closes #10120 [NO TESTS NEEDED] Signed-off-by: Jakob Ahrer <jakob@ahrer.dev>
* Fixes from make codespellDaniel J Walsh2021-04-21
| | | | Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* podman-remote should show podman.sock infoDaniel J Walsh2021-04-20
| | | | | | | | Currently podman-remote info does not show socket information. Fixes: https://github.com/containers/podman/issues/10077 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Merge pull request #10025 from zhangguanzhang/remote-save-dirOpenShift Merge Robot2021-04-19
|\ | | | | Fixes podman-remote save to directories does not work
| * Fixes podman-remote save to directories does not workzhangguanzhang2021-04-15
| | | | | | | | Signed-off-by: zhangguanzhang <zhangguanzhang@qq.com>
* | add --ip to podman play kubePaul Holzinger2021-04-16
| | | | | | | | | | | | | | | | | | | | Add a new --ip flag to podman play kube. This is used to specify a static IP address which should be used for the pod. This option can be specified several times because play kube can create more than one pod. Fixes #8442 Signed-off-by: Paul Holzinger <paul.holzinger@web.de>
* | Fix flake on failed podman-remote build : try 2Daniel J Walsh2021-04-14
|/ | | | | | | | | | | This time we are checking if the function actually succeeded, otherwise we will report an error. Also if we did not get the id, report unexpected failure. [NO TESTS NEEDED] Still no good way to test this, but manually. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Fix flake on failed podman-remote buildDaniel J Walsh2021-04-14
| | | | | | | | | | | | | | We have a race condition where podman build can fail but still return an exit code of 0. This PR ensures that as soon as the build fails, the failed flag is set eliminating the race. Fixes: https://github.com/containers/podman/issues/10029 [NO TESTS NEEDED] Tests of failed builds are already in place, and the elimination of the race should be enough. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Reflect current state of prune implementation in docsJakub Guzik2021-04-13
| | | | Signed-off-by: Jakub Guzik <jakubmguzik@gmail.com>
* [CI:DOCS] Correct status code for /pods/createJhon Honce2021-04-12
| | | | | | | | | | Swagger documentation reported that the API endpoint /pods/create returned 200 while the as-built code returned 201. 201 is more correct so documentation updated. Tests already checked for 201 so no updated needed. Signed-off-by: Jhon Honce <jhonce@redhat.com>
* Update manifest API endpointsJhon Honce2021-04-09
| | | | | | | | | | | | * Add validation for manifest name * Always return an array for manifests even if empty * Add missing return in df handler when returning error. Caused an additional null to be written to client crashing python decoder. When c/image is refactored to include manifests, manifest endpoints should be revisited. Signed-off-by: Jhon Honce <jhonce@redhat.com>
* Merge pull request #9971 from jwhonce/wip/dfOpenShift Merge Robot2021-04-08
|\ | | | | Add missing return
| * Add missing returnJhon Honce2021-04-08
| | | | | | | | | | | | | | libpod df handler missing a return after writing error to client. This caused a null to be appended to JSON and crashed python decoder. Signed-off-by: Jhon Honce <jhonce@redhat.com>
* | Merge pull request #9121 from tmds/swagger_remove_name_wildcardsOpenShift Merge Robot2021-04-08
|\ \ | | | | | | [NO TESTS NEEDED] swagger: remove name wildcards
| * | swagger: remove name wildcardsTom Deseyn2021-04-07
| | | | | | | | | | | | Signed-off-by: Tom Deseyn <tom.deseyn@gmail.com>
* | | Merge pull request #9968 from pablofsf/fix-libpod-container-wait-docsOpenShift Merge Robot2021-04-08
|\ \ \ | | | | | | | | [CI:DOCS] Adjust libpod API Container Wait documentation to the code
| * | | Adjust libpod API Container Wait documentation to the codePablo Correa Gómez2021-04-07
| | | | | | | | | | | | | | | | | | | | | | | | Closes #9960 Signed-off-by: Pablo Correa Gómez <ablocorrea@hotmail.com>
* | | | Merge pull request #9958 from jmguzik/limit-prune-filters-for-volumesOpenShift Merge Robot2021-04-07
|\ \ \ \ | |_|_|/ |/| | | Volumes prune endpoint should use only prune filters
| * | | Volumes prune endpoint should use only prune filtersJakub Guzik2021-04-07
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | Volumes endpoints for HTTP compat and libpod APIs allowed usage of list HTTP endpoint filter funcs. Documentation in case of compat API does not allow that. This commit aligns code with the documentation and also ligns libpod with compat API. Signed-off-by: Jakub Guzik <jakubmguzik@gmail.com>
* | | Merge pull request #9966 from jwhonce/wip/operation_idOpenShift Merge Robot2021-04-07
|\ \ \ | |_|/ |/| | [CI:DOCS] Update swagger definition of inspect manifest
| * | [CI:DOCS] Update swagger definition of inspect manifestJhon Honce2021-04-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Changed reference in swagger to correct struture that was being returned. * Added summary to ManifestAddLibpod to clean up generated web site * Added serve target to Makefile, to aid in debugging generated web site Signed-off-by: Jhon Honce <jhonce@redhat.com>
* | | Handle podman-remote --arch, --platform, --osDaniel J Walsh2021-04-07
| |/ |/| | | | | | | | | | | | | | | Podman remote should be able to handle remote specification of arches. Requires: https://github.com/containers/buildah/pull/3116 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | Merge pull request #9754 from mheon/add_depOpenShift Merge Robot2021-04-06
|\ \ | |/ |/| Add --requires flag to podman run/create
| * Add --requires flag to podman run/createMatthew Heon2021-04-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Podman has, for a long time, had an internal concept of dependency management, used mainly to ensure that pod infra containers are started before any other container in the pod. We also have the ability to recursively start these dependencies, which we use to ensure that `podman start` on a container in a pod will not fail because the infra container is stopped. We have not, however, exposed these via the command line until now. Add a `--requires` flag to `podman run` and `podman create` to allow users to manually specify dependency containers. These containers must be running before the container will start. Also, make recursive starting with `podman start` default so we can start these containers and their dependencies easily. Fixes #9250 Signed-off-by: Matthew Heon <matthew.heon@pm.me>
* | [CI:DOCS] Polish swagger OpertionIDsJhon Honce2021-04-06
| | | | | | | | | | | | | | | | Renamed 4 IDs to be consistent with other endpoints. Fixes #9951 Signed-off-by: Jhon Honce <jhonce@redhat.com>
* | [CI:DOCS] Set all operation id to be compatibileJhon Honce2021-04-05
| | | | | | | | | | | | | | | | | | Libpod operation id's changed to better match compatibile id Builds on https://github.com/containers/podman/pull/9123 and corrects a duplicated ID. Signed-off-by: Jhon Honce <jhonce@redhat.com>
* | Move operationIds to swagger:operation lineTom Deseyn2021-04-05
| | | | | | | | Signed-off-by: Tom Deseyn <tom.deseyn@gmail.com>
* | swagger: add operationIds that match with dockerTom Deseyn2021-04-05
| | | | | | | | Signed-off-by: Tom Deseyn <tom.deseyn@gmail.com>
* | Fix missing podman-remote build optionsDaniel J Walsh2021-04-02
| | | | | | | | | | | | | | | | | | | | | | | | | | Fix handling of SecurityOpts LabelOpts SeccompProfilePath ApparmorProfile Fix Ulimits Fixes: https://github.com/containers/podman/issues/9869 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>