Skip to content

jgrowl/vagrant-docker-compose

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Vagrant Provisioner: Docker Compose

A Vagrant provisioner for Docker Compose. Installs Docker Compose and can also bring up the containers defined by a docker-compose.yml.

Install

vagrant plugin install vagrant-docker-compose

Usage

To install docker and docker-compose

Vagrant.configure("2") do |config|
  config.vm.box = "ubuntu/trusty64"

  config.vm.provision :docker
  config.vm.provision :docker_compose
end

To install and run docker-compose on vagrant up

Vagrant.configure("2") do |config|
  config.vm.box = "ubuntu/trusty64"

  config.vm.provision :docker
  config.vm.provision :docker_compose, yml: "/vagrant/docker-compose.yml", run: "always"
end

Equivalent to running:

docker-compose -f [yml] up

To install, rebuild and run docker-compose on vagrant up

Vagrant.configure("2") do |config|
  config.vm.box = "ubuntu/trusty64"

  config.vm.provision :docker
  config.vm.provision :docker_compose, yml: "/vagrant/docker-compose.yml", rebuild: true, run: "always"
end

Equivalent to running:

docker-compose -f [yml] rm
docker-compose -f [yml] build
docker-compose -f [yml] up

Example

See example in the repository for a full working example.

About

A Vagrant provisioner for docker compose.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Ruby 97.3%
  • HTML 2.0%
  • Shell 0.7%