-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcommands
More file actions
37 lines (19 loc) · 752 Bytes
/
commands
File metadata and controls
37 lines (19 loc) · 752 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
$ docker version
$ docker info
$ docker container run -it -p 80:80 nginx
$ docker container ls or $ docker container ps or $ docker ps
$ docker container ls -a
$ docker container rm <id>
$ docker images
$ docker image rm <id>
$ docker pull nginx
$ docker container run -d -p 80:80 --name nginx-web nginx
$ docker container run -d -p 3306:3306 --name mysql --env MYSQL_ROOT_PASSWORD=<required password> mysql
$ docker container stop <name>
$ docker container rm -f <name>
$ docker container exec -it nginx-web bash
$ docker rm -f $(docker ps -qa)
$ docker container run -d -p 80:80 -v $(pwd):/usr/share/nginx/html --name nginx-web nginx
$ docker image build -t sreekanth31/nginx .
$ docker login
$ docker push sreekanth31/nginx