summaryrefslogtreecommitdiff
path: root/cmd/podman
Commit message (Collapse)AuthorAge
...
* | system service: remove unnecessary pointer to listnerPaul Holzinger2022-04-21
|/ | | | | | | Since the listener is already an interface there is no reason to use a extra pointer for it. Signed-off-by: Paul Holzinger <pholzing@redhat.com>
* Add missing events to podman-events man pageDaniel J Walsh2022-04-19
| | | | | | [NO NEW TESTS NEEDED] Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Add --quiet to machine lsBrent Baude2022-04-16
| | | | | | | | | | | | | The podman machine ls command would benefit from a --quiet flag which would only print the machine names without the extra information. It also implies --noheader as well. This can be helpful for scripting with the podman cli. Signed-off-by: Brent Baude <bbaude@redhat.com> [NO NEW TESTS NEEDED] Signed-off-by: Brent Baude <bbaude@redhat.com>
* Merge pull request #13849 from baude/defaultvolumessOpenShift Merge Robot2022-04-15
|\ | | | | Mount $HOME:$HOME by default in podman machine init
| * Add container.conf default volume to initBrent Baude2022-04-14
| | | | | | | | | | | | | | | | | | | | | | containers.conf now has a default volumes field for podman machine. this pr inserts those values as the default volumes in init. Signed-off-by: Brent Baude <bbaude@redhat.com> [NO NEW TESTS NEEDED] Signed-off-by: Brent Baude <bbaude@redhat.com>
* | Merge pull request #13868 from cdoern/cloneSwapOpenShift Merge Robot2022-04-15
|\ \ | | | | | | Fix Memory Swappiness passing in Container Clone
| * | Fix Memory Swappiness passing in Container Clonecdoern2022-04-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | `DefineCreateFlags` was excluding clone from using the memory-swappiness flag leading the value to be zero when our deafult is -1. Rearrange the if/else to give clone these memory related options resolves #13856 Signed-off-by: cdoern <cdoern@redhat.com>
* | | Merge pull request #13616 from giuseppe/passwd-entryOpenShift Merge Robot2022-04-14
|\ \ \ | |_|/ |/| | run, create: add --passwd-entry
| * | run, create: add --passwd-entryGiuseppe Scrivano2022-04-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | It allows to customize the entry that is written to the `/etc/passwd` file when --passwd is used. Closes: https://github.com/containers/podman/issues/13185 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* | | Merge pull request #13872 from vrothberg/revert-sizeOpenShift Merge Robot2022-04-14
|\ \ \ | |/ / |/| | Revert "images --size"
| * | Revert "images --size"Valentin Rothberg2022-04-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit e133a06d2f4a3e94bfbd60b647046f2f515c9c24. @nalind found a proper fix in c/storage [1] to address the performance issue. So we really don't need the flag anymore. Note the flag has never made it into any release. [1] https://github.com/containers/storage/commit/d76b3606fc9ca975bf436379f91105f0fac1555f Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* | | Merge pull request #13844 from Luap99/compat-netmodeOpenShift Merge Robot2022-04-13
|\ \ \ | | | | | | | | compat api: use network mode bridge as default
| * | | compat api: use network mode bridge as defaultPaul Holzinger2022-04-13
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For better docker compatibility we should use the bridge network mode as default for rootless. This was already done previously but commit 535818414c2a introduced this regression in v4.0. Since the apiv2 test are only run rootful we cannot catch this problem in CI. Signed-off-by: Paul Holzinger <pholzing@redhat.com>
* | | Merge pull request #13829 from baude/machineinspectOpenShift Merge Robot2022-04-13
|\ \ \ | |/ / |/| | Introduce machine inspect
| * | Introduce machine inspectBrent Baude2022-04-12
| |/ | | | | | | | | | | | | | | | | | | | | | | Allow users to inspect their podman virtual machines. This will be helpful for debug and development alike, because more details about the machine can be collected. Signed-off-by: Brent Baude <bbaude@redhat.com> [NO NEW TESTS NEEDED] Signed-off-by: Brent Baude <bbaude@redhat.com>
* | Merge pull request #13787 from Luap99/nohost-apiOpenShift Merge Robot2022-04-12
|\ \ | |/ |/| API: use no_hosts from containers.conf
| * API: use no_hosts from containers.confPaul Holzinger2022-04-11
| | | | | | | | | | | | | | | | | | The API endpoints should properly honour the `no_hosts=true` setting in containers.conf. Fixes #13719 Signed-off-by: Paul Holzinger <pholzing@redhat.com>
* | network create: add support for ipam-driver nonePaul Holzinger2022-04-11
|/ | | | | | | | | Add a new flag to set the ipam-driver. Also adds a new ipam driver none mode which only creates interfaces but does not assign addresses. Fixes #13521 Signed-off-by: Paul Holzinger <pholzing@redhat.com>
* images --sizeValentin Rothberg2022-04-08
| | | | | | | | | | Add a --size option to podman images to allow for disabling computing the size of listed images. If listing images is critical to performance, user may chose to turn off size computation to speed things up. Context: #13755 Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* Merge pull request #13490 from gcalin/13266OpenShift Merge Robot2022-04-04
|\ | | | | pod logs enhancements: option to color logs
| * Add option for pod logs to display different colors per container.gcalin2022-03-29
| | | | | | | | | | Signed-off-by: Krzysztof Baran <krysbaran@gmail.com> Signed-off-by: gcalin <caling@protonmail.com>
* | specgen: do not set OOMScoreAdj by defaultGiuseppe Scrivano2022-04-04
| | | | | | | | | | | | | | | | | | do not force a value of OOMScoreAdj=0 if it is wasn't specified by the user. Closes: https://github.com/containers/podman/issues/13731 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* | cli commands: better error for unsupported commandsPaul Holzinger2022-03-31
|/ | | | | | | | | | | | | | | | When you run podman-remote unsahre for example you currently get: Error: unrecognized command `podman-remote unshare` This is because we do not add the command to the cobra tree when we run in remote mode. However this is a bad user experience since it is not clear that the command is only supported for local podman. Users are left wondering why this does not work and could think the documentation is wrong. To fix it we add a clear error message: Error: cannot use command "podman-remote unshare" with the remote podman client Signed-off-by: Paul Holzinger <pholzing@redhat.com>
* Machine refactor - part 1Brent Baude2022-03-28
| | | | | | | | | | | | | | | | the way machine was written was very adjunct and as such is in dire need of refactoring to better structures and structure methods where appropriate. the weekest part is specifically around all the files that machine requires and how some are just dynamically built on the fly. this pr defines a new machinefile type which allows us to work with the file and also takes into account the use of symlinks which are going to be needed on macos due to its relatively short file length restriction. also, added unit tests for new methods as well as anywhere else I saw a need. Signed-off-by: Brent Baude <bbaude@redhat.com>
* Merge pull request #13660 from rhatdan/errorOpenShift Merge Robot2022-03-27
|\ | | | | Remove error stutter
| * Remove error stutterDaniel J Walsh2022-03-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When podman gets an error it prints out "Error: " before printing the error string. If the error message starts with error, we end up with Error: error ... This PR Removes all of these stutters. logrus.Error() also prints out that this is an error, so no need for the error stutter. [NO NEW TESTS NEEDED] Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* | Run codespell to cleanup typosDaniel J Walsh2022-03-25
|/ | | | | | [NO NEW TESTS NEEDED] Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* Merge pull request #13587 from giuseppe/clone-to-podOpenShift Merge Robot2022-03-24
|\ | | | | container: allow clone to an existing pod
| * container: allow clone to an existing podGiuseppe Scrivano2022-03-24
| | | | | | | | | | | | Closes: https://github.com/containers/podman/issues/3979 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* | Merge pull request #13606 from paralin/play-kube-inmemOpenShift Merge Robot2022-03-24
|\ \ | | | | | | play: kube: support io.reader body arg and remove tempfiles
| * | play: kube: use in-memory kubefile and remove tempfileChristian Stewart2022-03-24
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The PlayKube and PlayKubeDown commands accepted a "path" argument to a YAML file to play. This requires the caller to write the YAML to a file path. The downside of this is apparent in the HTTP handlers which have to use a temporary file on disk to store the YAML file. The file is opened & used as the body of the HTTP request. It's possible to instead pass a io.Reader and use a fully in-memory request body. Add backwards-compatible changes to bindings to allow passing either a filepath or a io.Reader body. Refactor the podman bindings to use a io.Reader instead of a filepath. Simplify the HTTP handlers for PlayKube by removing the now unneeded tempfile. [NO NEW TESTS NEEDED] Signed-off-by: Christian Stewart <christian@paral.in>
* / machine-set: fix example for setting rootful flagAditya R2022-03-24
|/ | | | | | | | | | | | Flag is actually named `rootful` however documented as `root`, fix the documented example as actual flag. Both `podman machine init` and `podman machine set` uses flag `rootfull` [NO TESTS NEEDED] [NO NEW TESTS NEEDED] Signed-off-by: Aditya R <arajan@redhat.com>
* Merge pull request #13588 from flouthoc/import-os-archOpenShift Merge Robot2022-03-23
|\ | | | | import: allow users to set `--os`, `--arch` and `--variant` of image imports
| * import: allow users to set os, arch and variant of importsAditya R2022-03-23
| | | | | | | | | | | | | | | | | | | | Allows users to set `--os` , `--arch` and `--variant` of the image created from the custom import. Following is useful when user is already aware of the values which are correct for their generated rootfs Signed-off-by: Aditya R <arajan@redhat.com>
* | fix a number of errcheck issuesValentin Rothberg2022-03-22
| | | | | | | | | | | | Numerous issues remain, especially in tests/e2e. Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* | fix a number of `godot` issuesValentin Rothberg2022-03-22
| | | | | | | | | | | | | | Still an unknown number remains but I am running out of patience. Adding dots is not the best use of my time. Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* | linter: enable nilerrValentin Rothberg2022-03-22
| | | | | | | | | | | | | | A number of cases looked suspicious, so I marked them with `FIXME`s to leave some breadcrumbs. Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* | linter: enable wastedassignValentin Rothberg2022-03-22
|/ | | | Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* Merge pull request #13575 from Luap99/percentOpenShift Merge Robot2022-03-21
|\ | | | | podman system df: fix percent calculation
| * podman system df: fix percent calculationPaul Holzinger2022-03-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The calculate the percentage we need floating point numbers. The current code however casted the result of reclaimable/size to an int first. Casting to an int in go will just discard the decimal points, thus the result was either 0 or 1 so if multiplied by 100 it would show up as 0% or 100%. To fix this we have to multiply by 100 first before casting the result to an int. Also add a check for div by zero which results in NaN and use math.Round() to correctly round a number. Ref #13516 Signed-off-by: Paul Holzinger <pholzing@redhat.com>
* | Merge pull request #13573 from vrothberg/golangci-lintOpenShift Merge Robot2022-03-21
|\ \ | |/ |/| bump golangci-lint to v1.45.0
| * bump golangci-lint to v1.45.0Valentin Rothberg2022-03-21
| | | | | | | | | | | | | | | | | | | | * supports Go 1.18 * disable a number of new linters * fix minor stylecheck issues [NO NEW TESTS NEEDED] Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* | Merge pull request #13541 from vrothberg/rmi-ignoreOpenShift Merge Robot2022-03-21
|\ \ | |/ |/| podman rmi --ignore
| * podman rmi --ignoreValentin Rothberg2022-03-19
| | | | | | | | | | | | | | | | | | | | | | Add an `--ignore` flag to `podman image rm` to instruct ignoring image if a specified image does not exist and to not throw an error. Other commands (e.g., `podman container rm`) already support this flag. Such an `--ignore` flag can come in handy in clean-up scripcts such as the teardown phases in the Podman tests. Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
* | Fix type-o and cleanup doc punctuationJason T. Greene2022-03-18
|/ | | | Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
* Merge pull request #13540 from mheon/fix_11822OpenShift Merge Robot2022-03-18
|\ | | | | Deduplicate between Volumes and Mounts in compat API
| * Deduplicate between Volumes and Mounts in compat APIMatthew Heon2022-03-17
| | | | | | | | | | | | | | | | | | | | | | | | | | Docker Compose v2.0 passes mount specifications in two different places: Volumes (just the destination) and Mounts (full info provided - source, destination, etc). This was causing Podman to refuse to create containers, as the destination was used twice. Deduplicate between Mounts and Volumes, preferring volumes, to resolve this. Fixes #11822 Signed-off-by: Matthew Heon <mheon@redhat.com>
* | Merge pull request #13523 from n1hility/tolerate-old-machineOpenShift Merge Robot2022-03-18
|\ \ | | | | | | Tolerate old machine images, but warn they should be recreated
| * | Handle incompatible machinesJason T. Greene2022-03-18
| |/ | | | | | | | | | | Start in a reduced mode for recovery, warn, and provide instructions to recreate them Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
* / go fmt: use go 1.18 conditional-build syntaxValentin Rothberg2022-03-18
|/ | | | Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>