diff options
-rw-r--r-- | docker.md | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/docker.md b/docker.md new file mode 100644 index 0000000..4443e13 --- /dev/null +++ b/docker.md @@ -0,0 +1,13 @@ +# Docker containers + +## `docker run` + +* `--rm` will remove the Docker container after running the command (otherwise + have to do it manually if you want to run another one-shot command) +* `-v <local path>:<container path>`: mount a volume +* `--entrypoint <command>`: use custom entry point, not from Dockerfile. Specify + just the command, give arguments after specifying image. + +## `docker exec` + +Runs a command against a *running* container. |