This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
|
docker:import_run_image [2020/03/03 16:15] admin created |
docker:import_run_image [2020/03/03 16:26] (current) admin |
||
|---|---|---|---|
| Line 36: | Line 36: | ||
| </code> | </code> | ||
| + | |||
| + | Then you can install docker image from github: | ||
| + | |||
| + | <code bash> | ||
| + | docker run httpd | ||
| + | </code> | ||
| + | |||
| + | <code bash> | ||
| + | [root@localhost ~]# docker images -a | ||
| + | REPOSITORY TAG IMAGE ID CREATED SIZE | ||
| + | httpd latest c5a012f9cf45 6 days ago 165MB | ||
| + | </code> | ||
| + | |||
| + | Then you can run image and "image" became docker container: | ||
| + | |||
| + | <code bash> | ||
| + | docker run -d httpd | ||
| + | </code> | ||
| + | or | ||
| + | <code bash> | ||
| + | docker run -d c5a012f9cf45 | ||
| + | </code> | ||
| + | |||
| + | Check is it docker container running : | ||
| + | |||
| + | <code bash> | ||
| + | docker ps -a | ||
| + | </code> | ||
| + | |||
| + | <code bash> | ||
| + | [root@localhost ~]# docker ps -a | ||
| + | CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES | ||
| + | 5154f5756a7a httpd "httpd-foreground" 43 seconds ago Up 42 seconds 80/tcp ecstatic_kare | ||
| + | |||
| + | </code> | ||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||