meta data for this page
This is an old revision of the document!
Docker
docker ps -a docker run -it -rm <container> bash whoami exit
| Command | Description | |
|---|---|---|
run <image>[:tag] [command] | run container/image | |
| Basic | ||
-it | –interactive and –tty | |
–rm | remove container | |
-d | run in background | |
-v [host-folder]:[container-folder] | add volume | |
| Extended | ||
–name [name] | define container name | |
-e <env>, –env-file <env-file> | add env | |
-h <hostname> | set hostname | |
-m <memory> | set memory limit | |
| Compose | ||
| compose up | down [-d] | |
| Others | ||
search <searchword> | search registry | |
search -f is-official=true <sw> | ||
search -f stars=100 <sw> | ||