diff --git a/in/public/containers/docker/host.rst b/in/public/containers/docker/host.rst new file mode 100644 index 0000000..9f000b2 --- /dev/null +++ b/in/public/containers/docker/host.rst @@ -0,0 +1,75 @@ +Host +==== + +Stats +----- + +.. code:: shell + + docker info + +Images +------ + +List +^^^^ + +.. code:: shell + + docker images + +Import +^^^^^^ + +.. code:: shell + + docker import archive_name.tar repository_name:image_name + +Remove +^^^^^^ + +.. code:: shell + + docker image rm image_name + +Containers +---------- + +List +^^^^ + +.. code:: shell + + docker ps --all + +Create +^^^^^^ + +.. code:: shell + + docker create \ + --name container_name \ + --publish host_port:container_port \ + repository_name:image_name \ + command argument_1 … + +Start +^^^^^ + +.. code:: shell + + docker start container_name + +Stop +^^^^ + +.. code:: shell + + docker stop container_name + +Remove +^^^^^^ + +.. code:: shell + + docker rm container_name diff --git a/in/public/containers/docker/index.rst b/in/public/containers/docker/index.rst new file mode 100644 index 0000000..9af23e9 --- /dev/null +++ b/in/public/containers/docker/index.rst @@ -0,0 +1,6 @@ +Docker +====== + +.. toctree:: + + host diff --git a/in/public/containers/index.rst b/in/public/containers/index.rst index 8af93cb..29aa76a 100644 --- a/in/public/containers/index.rst +++ b/in/public/containers/index.rst @@ -5,3 +5,4 @@ Containers :maxdepth: 2 lxc/index + docker/index