From 6380b42edbf98dec3b04b3b74fcfbfd63dba4034 Mon Sep 17 00:00:00 2001 From: Thijs Terlouw Date: Tue, 3 Sep 2013 16:35:22 +0200 Subject: [PATCH] Add 2 missing cli commands to docs (events + insert) and alphabetically order docker output --- AUTHORS | 1 + commands.go | 2 +- docs/sources/commandline/command/events.rst | 34 +++++++++++++++++++++ docs/sources/commandline/command/insert.rst | 23 ++++++++++++++ docs/sources/commandline/index.rst | 2 ++ 5 files changed, 61 insertions(+), 1 deletion(-) create mode 100644 docs/sources/commandline/command/events.rst create mode 100644 docs/sources/commandline/command/insert.rst diff --git a/AUTHORS b/AUTHORS index 5bf18aa51d..791d966cef 100644 --- a/AUTHORS +++ b/AUTHORS @@ -104,6 +104,7 @@ Solomon Hykes Sridhar Ratnakumar Stefan Praszalowicz Thatcher Peskens +Thijs Terlouw Thomas Bikeev Thomas Hansen Tianon Gravi diff --git a/commands.go b/commands.go index 0b276ff77f..ffa94973bf 100644 --- a/commands.go +++ b/commands.go @@ -91,7 +91,6 @@ func (cli *DockerCli) CmdHelp(args ...string) error { {"login", "Register or Login to the docker registry server"}, {"logs", "Fetch the logs of a container"}, {"port", "Lookup the public-facing port which is NAT-ed to PRIVATE_PORT"}, - {"top", "Lookup the running processes of a container"}, {"ps", "List containers"}, {"pull", "Pull an image or a repository from the docker registry server"}, {"push", "Push an image or a repository to the docker registry server"}, @@ -103,6 +102,7 @@ func (cli *DockerCli) CmdHelp(args ...string) error { {"start", "Start a stopped container"}, {"stop", "Stop a running container"}, {"tag", "Tag an image into a repository"}, + {"top", "Lookup the running processes of a container"}, {"version", "Show the docker version information"}, {"wait", "Block until a container stops, then print its exit code"}, } { diff --git a/docs/sources/commandline/command/events.rst b/docs/sources/commandline/command/events.rst new file mode 100644 index 0000000000..b8dd591fb1 --- /dev/null +++ b/docs/sources/commandline/command/events.rst @@ -0,0 +1,34 @@ +:title: Events Command +:description: Get real time events from the server +:keywords: events, docker, documentation + +================================================================= +``events`` -- Get real time events from the server +================================================================= + +:: + + Usage: docker events + + Get real time events from the server + +Examples +-------- + +Starting and stopping a container +................................. + +.. code-block:: bash + + $ sudo docker start 4386fb97867d + $ sudo docker stop 4386fb97867d + +In another shell + +.. code-block:: bash + + $ sudo docker events + [2013-09-03 15:49:26 +0200 CEST] 4386fb97867d: (from 12de384bfb10) start + [2013-09-03 15:49:29 +0200 CEST] 4386fb97867d: (from 12de384bfb10) die + [2013-09-03 15:49:29 +0200 CEST] 4386fb97867d: (from 12de384bfb10) stop + diff --git a/docs/sources/commandline/command/insert.rst b/docs/sources/commandline/command/insert.rst new file mode 100644 index 0000000000..0f2612c9af --- /dev/null +++ b/docs/sources/commandline/command/insert.rst @@ -0,0 +1,23 @@ +:title: Insert Command +:description: Insert a file in an image +:keywords: insert, image, docker, documentation + +========================================================================== +``insert`` -- Insert a file in an image +========================================================================== + +:: + + Usage: docker insert IMAGE URL PATH + + Insert a file from URL in the IMAGE at PATH + +Examples +-------- + +Insert file from github +....................... + +.. code-block:: bash + + $ sudo docker insert 8283e18b24bc https://raw.github.com/metalivedev/django/master/postinstall /tmp/postinstall.sh diff --git a/docs/sources/commandline/index.rst b/docs/sources/commandline/index.rst index 5c2b373205..0e7c8738b3 100644 --- a/docs/sources/commandline/index.rst +++ b/docs/sources/commandline/index.rst @@ -17,11 +17,13 @@ Contents: commit cp diff + events export history images import info + insert inspect kill login