0%

How to use docker to run your task

A example about how to use docker to run your task. That is:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
1. Pull the images or repository from registry
docker pull reg.docker.alibaba-inc.com/alinux/kdevel-x64:3.230303.1

2. List the images
docker images

3. Start the container and interact through terminal
docker run -itd --net host -v /mnt/sdb/zhaoguanjun.zgj/:/root/workspace reg.docker.alibaba-inc.com/alinux/kdevel-x64 bash

4. List all the containers
docker ps -a

5. Execute the container
docker exec -it [container-id] bash

6. Exit the container
Execute 'exit' in docker terminal

7. Kill the container
docker kill [container-id]

8. Remove the container or images
docker rm [container-id]

This document will be continuously improved.

正在加载今日诗词....