summaryrefslogtreecommitdiff
path: root/cmd/podman/commands.go
Commit message (Collapse)AuthorAge
* Podman V2 birthBrent Baude2020-04-16
| | | | | | remote podman v1 and replace with podman v2. Signed-off-by: Brent Baude <bbaude@redhat.com>
* Add support for containers.confDaniel J Walsh2020-03-27
| | | | | | | vendor in c/common config pkg for containers.conf Signed-off-by: Qi Wang qiwan@redhat.com Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* auto updatesValentin Rothberg2020-03-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support to auto-update containers running in systemd units as generated with `podman generate systemd --new`. `podman auto-update` looks up containers with a specified "io.containers.autoupdate" label (i.e., the auto-update policy). If the label is present and set to "image", Podman reaches out to the corresponding registry to check if the image has been updated. We consider an image to be updated if the digest in the local storage is different than the one of the remote image. If an image must be updated, Podman pulls it down and restarts the container. Note that the restarting sequence relies on systemd. At container-creation time, Podman looks up the "PODMAN_SYSTEMD_UNIT" environment variables and stores it verbatim in the container's label. This variable is now set by all systemd units generated by `podman-generate-systemd` and is set to `%n` (i.e., the name of systemd unit starting the container). This data is then being used in the auto-update sequence to instruct systemd (via DBUS) to restart the unit and hence to restart the container. Note that this implementation of auto-updates relies on systemd and requires a fully-qualified image reference to be used to create the container. This enforcement is necessary to know which image to actually check and pull. If we used an image ID, we would not know which image to check/pull anymore. Fixes: #3575 Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
* Move podman-service to podman-system-serviceMatthew Heon2020-02-06
| | | | | | Fixes #5108 Signed-off-by: Matthew Heon <mheon@redhat.com>
* Add service endpointbaude2020-01-21
| | | | | | | | | | | | | | | | | | | | | | | | | | add service endpoint for the new API. Also supports the varlink implementation. Signed-off-by: baude <bbaude@redhat.com> Refactor to allow developer more control of API server * Add api.NewServerWithSettings() to create an API server with custom settings * Add api.ListenUnix() to create a UDS net.Listener and setup UDS Signed-off-by: Jhon Honce <jhonce@redhat.com> Signed-off-by: baude <bbaude@redhat.com> More service completion Add podman service command that allows users to run either a RESTful or varlink protocol API service. Addition of docs and RESTful listening. Signed-off-by: baude <bbaude@redhat.com> Signed-off-by: Brent Baude <bbaude@redhat.com>
* podman-remote image trust is brokenDaniel J Walsh2019-09-11
| | | | | | We should not be making it available, it does nothing. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* podman-remote: cp crashesbaude2019-08-21
| | | | | | | | | | prune unwanted messages when running a container remotely. also, cp is not remote-enabled yet and as such should not be available on the remote client. Fixes: #3861 Signed-off-by: baude <bbaude@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>
* 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>
* Remove umount command from remote client.Ashley Cui2019-06-27
| | | | | | Since there is no mount command, it does not make sense to have umount. Signed-off-by: Ashley Cui <ashleycui16@gmail.com>
* 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>
* Add unshare to podmanDivyansh Kamboj2019-05-16
| | | | | | | This command lets the user run a command in a new user namespace like `unshare -u`. It uses the implementation of unshare in buildah. ( fixes #1388 ) Signed-off-by: Divyansh Kamboj <kambojdivyansh2000@gmail.com>
* remote-podman checkpoint and restore add to container submenubaude2019-05-06
| | | | | | | the remote-podman checkpoint and restore commands were done some time ago but for some reason not added to the container subcommand Signed-off-by: baude <bbaude@redhat.com>
* podman-remote portbaude2019-05-01
| | | | | | | add the port command to the remote client. this allows users to displa port information about their host system from the remote client Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #2982 from baude/remotecontainerpruneOpenShift Merge Robot2019-04-30
|\ | | | | podman-remote prune containers
| * podman-remote prune containersbaude2019-04-26
| | | | | | | | | | | | | | enable the ability to prune containers from the remote-command. this also includes the system prune command. Signed-off-by: baude <bbaude@redhat.com>
* | podman-remote stopbaude2019-04-29
| | | | | | | | | | | | | | add stop to the container subcommands for the remote client. the stop function is already done. this is a graphical change only. Signed-off-by: baude <bbaude@redhat.com>
* | system: add new subcommand "migrate"Giuseppe Scrivano2019-04-26
|/ | | | | | | | | | | it is useful to migrate existing containers to a new version of podman. Currently, it is needed to migrate rootless containers that were created with podman <= 1.2 to a newer version which requires all containers to be running in the same user namespace. Closes: https://github.com/containers/libpod/issues/2935 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* enable podman remote topbaude2019-04-25
| | | | | | | add the ability for the remote client to display a container's running processes. Signed-off-by: baude <bbaude@redhat.com>
* podman remote-client restart containersbaude2019-04-24
| | | | | | add the ability to restart containers with the remote-client Signed-off-by: baude <bbaude@redhat.com>
* podman-remote pause|unpausebaude2019-04-18
| | | | | | | | Add the ability to pause and unpause containers with the remote client. Also turned on the pause tests! Signed-off-by: baude <bbaude@redhat.com>
* podman-remote startbaude2019-04-17
| | | | | | | enable the ability to start containers from the remote-client. also, enable start integration tests for remote testing. Signed-off-by: baude <bbaude@redhat.com>
* podman-remote container commandsbaude2019-04-16
| | | | | | | Several container commands were ported to the remote client but had not been updated on the container submenu yet. Signed-off-by: baude <bbaude@redhat.com>
* podman-remote generate kubebaude2019-04-12
| | | | | | Allow the ability to generate kube YAML from the podman remote-client. Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #2892 from edsantiago/healthcheck_typo_fixOpenShift Merge Robot2019-04-10
|\ | | | | (minor): fix misspelled 'Healthcheck'
| * (minor): fix misspelled 'Healthcheck'Ed Santiago2019-04-10
| | | | | | | | Signed-off-by: Ed Santiago <santiago@redhat.com>
* | Add the ability to attach remotely to a containerbaude2019-04-10
|/ | | | | | | | | | | | | | | | | | | | | Also, you can now podman-remote run -it. There are some bugs that need to be ironed out but I would prefer to merge this so we can make both progress on start and exec as well as the bugs. * when doing podman-remote run -it foo /bin/bash, you have to press enter to get the prompt to display. with the localized podman, we had to teach it connect to the console first and then start the container so we did not miss anything. * when executing "exit" in the console, we get a hard lockup likely because nobody knows what to do. * custom detach keys are not supported * podman-remote run -it alpine ls does not currently work. only dropping to a shell works. Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #2882 from baude/remotepsOpenShift Merge Robot2019-04-10
|\ | | | | podman-remote ps
| * podman-remote psbaude2019-04-09
| | | | | | | | | | | | add the ability to run ps on containers using the remote client. Signed-off-by: baude <bbaude@redhat.com>
* | Implement podman-remote rmJhon Honce2019-04-09
|/ | | | | | | | | * refactor command output to use one function * Add new worker pool parallel operations * Implement podman-remote umount * Refactored podman wait to use printCmdOutput() Signed-off-by: Jhon Honce <jhonce@redhat.com>
* podman-remote create|runbaude2019-04-08
| | | | | | | | | | | | | | add the ability to create and run containers via the podman-remote client. we now create an intermediate layer from the the create/run cli flags. the intermediate layer can be converted into a createconfig or into a varlink struct. Once transported, the varlink struct can be converted back to an intermediate layer and then to a createconfig. remote terminals are not supported yet. Signed-off-by: baude <bbaude@redhat.com>
* add remote-client diffbaude2019-04-03
| | | | | | | the remote client now can run the diff command to report changes, modifications, and deletions in an image or container. Signed-off-by: baude <bbaude@redhat.com>
* system df to show podman disk usageQi Wang2019-03-25
| | | | Signed-off-by: Qi Wang <qiwan@redhat.com>
* display logs for multiple containers at the same timebaude2019-03-15
| | | | | | | | | | | | | | add the ability for users to specify more than one container at a time while using podman logs. If more than one container is being displayed, podman will also prepend a shortened container id of the container on the log line. also, enabled the podman-remote logs command during the refactoring of the above ability. fixes issue #2219 Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #2534 from jwhonce/wip/remote_waitOpenShift Merge Robot2019-03-06
|\ | | | | Implement podman-remote wait command and container subcommand
| * Implement podman-remote wait command and container subcommandJhon Honce2019-03-06
| | | | | | | | Signed-off-by: Jhon Honce <jhonce@redhat.com>
* | Merge pull request #2442 from baude/remotepodtopOpenShift Merge Robot2019-03-06
|\ \ | |/ |/| podman-remote pod top|stats
| * podman-remote pod top|statsbaude2019-03-06
| | | | | | | | | | | | | | this is the final enablement for the pod subcommand. it includes the ability to run podman-remote pod top and stats. Signed-off-by: baude <bbaude@redhat.com>
* | podman healthcheck run (phase 1)baude2019-03-05
|/ | | | | | | | | Add the ability to manually run a container's healthcheck command. This is only the first phase of implementing the healthcheck. Subsequent pull requests will deal with the exposing the results and history of healthchecks as well as the scheduling. Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #2364 from jwhonce/wip/remote_stopOpenShift Merge Robot2019-03-04
|\ | | | | Support podman-remote stop container
| * Support podman-remote stop container(s)Jhon Honce2019-03-02
| | | | | | | | | | | | | | | | | | | | * Clean up adapter code * Add GetContainersByContext to Varlink API * Add missing comments * Restore save command * Restore error type mapping when using varlink Signed-off-by: Jhon Honce <jhonce@redhat.com>
* | Fix aliased commands to actually workDaniel J Walsh2019-03-03
|/ | | | | | | | | | | | | | | | | The current aliased commands podman container list and podman image list podman image rm Do not work properly. The global storage options are broken. This patch fixes this issue. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
* fix up a number of misplace commandsbaude2019-02-28
| | | | | | | | | * ps now on main command * sign is no longer on main commmand * ls, list no longer are valid main aliases for images * ls, list does work for podman image Signed-off-by: baude <bbaude@redhat.com>
* fix up a number of misplace commandsbaude2019-02-27
| | | | | | | | | * ps now on main command * sign is no longer on main commmand * ls, list no longer are valid main aliases for images * ls, list does work for podman image Signed-off-by: baude <bbaude@redhat.com>
* Remove restore as podman subcommandAdrian Reber2019-02-27
| | | | | | | | The commands checkpoint and restore should only be available under 'podman container'. This is probably a result of the recent cobra migration. Signed-off-by: Adrian Reber <areber@redhat.com>
* podman-remote pod pause|unpause|restartbaude2019-02-25
| | | | | | | enable the ability for the remote client to pause, unpause, and restart pods. Signed-off-by: baude <bbaude@redhat.com>
* Merge pull request #2422 from baude/remotepodcreateOpenShift Merge Robot2019-02-25
|\ | | | | podman-remote create|ps
| * podman-remote create|psbaude2019-02-25
| | | | | | | | | | | | | | enable the podman-remote client to be able to create and list pods on a remote system. Signed-off-by: baude <bbaude@redhat.com>
* | remove duplicate commands in mainbaude2019-02-25
| | | | | | | | | | | | | | | | | | | | | | kube was erronously being added as main subcommand multiple times. it should not be a subcommand as it should live under either play or generate. also removing the addition of the volume command from the commands.go to eliminate a duplicate. Signed-off-by: baude <bbaude@redhat.com>
* | Merge pull request #2419 from rhatdan/playOpenShift Merge Robot2019-02-24
|\ \ | |/ |/| Fix play to show up in podman help