docker-machine active

active See which machine is “active” (a machine is considered active if the DOCKER_HOST environment variable points to it). $ docker-machine ls NAME ACTIVE DRIVER STATE URL dev - virtualbox Running tcp://192.168.99.103:2376 staging * digitalocean Running tcp://203.0.113.81:2376 $ echo $DOCKER_HOST tcp://203.0.113.81:2376 $ docker-machine active staging

docker-compose up

up Usage: up [options] [SERVICE...] Options: -d Detached mode: Run containers in the background, print new container names. Incompatible with --abort-on-container-exit. --no-color Produce monochrome output. --no-deps Don't start linked services. --force-recreate Recreate containers even if their configuration and image h

docker-compose stop

stop Usage: stop [options] [SERVICE...] Options: -t, --timeout TIMEOUT Specify a shutdown timeout in seconds (default: 10). Stops running containers without removing them. They can be started again with docker-compose start.

docker-compose unpause

unpause Usage: unpause [SERVICE...] Unpauses paused containers of a service.

docker-compose start

start Usage: start [SERVICE...] Starts existing containers for a service.

docker-compose run

run Usage: run [options] [-e KEY=VAL...] SERVICE [COMMAND] [ARGS...] Options: -d Detached mode: Run container in the background, print new container name. --name NAME Assign a name to the container --entrypoint CMD Override the entrypoint of the image. -e KEY=VAL Set an environment variable (can be used multiple times) -u, --user="" Run as specified username or uid --no-deps Don't start linked services.

docker-compose scale

scale Usage: scale [SERVICE=NUM...] Sets the number of containers to run for a service. Numbers are specified as arguments in the form service=num. For example: $ docker-compose scale web=2 worker=3

docker-compose rm

rm Usage: rm [options] [SERVICE...] Options: -f, --force Don't ask to confirm removal -v Remove any anonymous volumes attached to containers -a, --all Also remove one-off containers created by docker-compose run Removes stopped service containers. By default, anonymous volumes attached to containers will not be removed. You can override this with -v. To list all volumes, use docker volume ls. Any data which is not in a volume will be lost.

docker-compose restart

restart Usage: restart [options] [SERVICE...] Options: -t, --timeout TIMEOUT Specify a shutdown timeout in seconds. (default: 10) Restarts services.

docker-compose ps

ps Usage: ps [options] [SERVICE...] Options: -q Only display IDs Lists containers.