JAEN

Docker

docker run

CautionRun a container

docker run -d -p 80:80 <image>

Starts a container from an image; -d detached, -p ports, -v volumes.

Examples

  • docker run -d -p 8080:80 --name web nginxRun nginx on 8080

Syntax

docker run [-d] [-it] [-p host:cont] [-v vol:path] [--name n] <image>

Before you run it

Mind exposed ports and mounts.

Related commands

The same reference, with no signal at all

Every command on this site, held on your device. The app adds 632 more: 1,510 commands and 120 fix flows, searchable with no connection. Free to install, no ads (some content is a one-time purchase).

Get it free on the App Store