git clone https://github.com/linderun/docker-compose.git
cd docker-compose && cp .env.example .env
Edit the .env
file and set the config for the docker compose after you copy the .env
.example file.
docker-compose build
docker-compose up -d
If you want to run your services in the background, you can pass the -d
flag (for “detached” mode) to docker-compose up
and use docker-compose ps
to see what is currently running:
docker-compose ps
The docker-compose run
command allows you to run one-off commands for your services. For example, to see what environment variables are available to the nginx
service:
docker-compose run nginx env
If you started Compose with docker-compose up -d
, stop your services once you’ve finished with them:
docker-compose stop
The project is open-sourced software licensed under the MIT license.
Web Site: Darren Lin