Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
O orientation
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 9
    • Issues 9
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge requests 36
    • Merge requests 36
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Container Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Newbies
  • orientation
  • Wiki
  • dockerBasics

dockerBasics · Changes

Page history
Update dockerBasics authored Jun 15, 2020 by Yogesh Hegde's avatar Yogesh Hegde
Hide whitespace changes
Inline Side-by-side
Showing with 13 additions and 25 deletions
+13 -25
  • dockerBasics.md dockerBasics.md +13 -25
  • No files found.
dockerBasics.md
View page @ ff42dfa3
......@@ -8,7 +8,7 @@
1. [Docker Terminologies](#docker-terminologies)
2. [Docker Installation (ubuntu16.04)](#docker-installation)
4. [Docker Basic Command](#docker-basic-commands)
5. [Common Docker operations](#creating-an-application)
5. [Common Docker operations](#common-operations-on-dockers)
## Why docker ?
......@@ -71,6 +71,8 @@ Learn basic docker commands
## docker ps
* The docker ps command allows us to view all the containers that are running on the Docker Host.
for Example:
```sh
$ docker ps
......@@ -78,26 +80,8 @@ CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
30986b73dc00 ubuntu "bash" 45 minutes ago Up About a minute elated_franklin
```
docker ps output details
* **CONTAINER ID:** A unique string consisting of alphanumeric characters, associated with each container.
* **IMAGE:** Name of the Docker Image used to create this container.
* **COMMAND:** Any application-specific command(s) that needs to be executed when the container is started.
* **CREATED:** This shows the time elapsed since this container has been created.
* **STATUS:** This shows the current status of the container, along with the time elapsed, in its present state.
* **PORTS:** This displays any port mappings defined for the container.
* **Names:** Apart from the CONTAINER ID, each container is also assigned a unique name. We can refer to a container either using its container ID or its unique name.
## docker start
* This command starts any stopped container(s).
* Syntax
```sh
$ docker start [options] CONTAINER ID/NAME [CONTAINER ID/NAME…]
```
* Example
```sh
$ docker start 30986
......@@ -110,10 +94,6 @@ Whereas in this example, Docker starts the container named sneha.
## docker stop
* This command stops any running container(s).
* Syntax
```sh
$ docker stop [options] CONTAINER ID/NAME [CONTAINER ID/NAME…]
```
* Example
```sh
$ docker stop 30986
......@@ -124,10 +104,18 @@ $ docker stop sneha
```
Whereas in this example, Docker will stop the container named sneha.
## docker restart
## docker run
* This command creates containers from docker images.
* Example
```sh
$ docker run sneha
```
## docker rm
* This command deletes the containers.
* Example
```sh
$ docker rm sneha
```
## Common Operations on Dockers
......
Clone repository
  • 20hrLearning
  • Code Workspace
  • Culture
  • FAQ
  • Home
  • Installing Required Tools
  • codeworkspace
  • codingStyle
  • coding_style_c_cpp
  • coding_style_python
  • dockerBasics
  • gitBasics
  • gitlabBasics
  • install tools ubuntu 16.04
  • install tools windows
View All Pages