website/docs: Add an example on how to run multiple containers based off the same image

This commit is contained in:
Fabio Rehm 2013-12-05 22:13:46 -02:00
parent 8688c6b8b2
commit bdd4e82e49
1 changed files with 12 additions and 0 deletions

View File

@ -110,3 +110,15 @@ Vagrant.configure("2") do |config|
end end
end end
``` ```
In case you need to run multiple containers based off the same image, you can do
so by providing different names and specifying the `image` parameter to it:
```ruby
Vagrant.configure("2") do |config|
config.vm.provision "docker" do |d|
d.run "db-1", image: "user/mysql"
d.run "db-2", image: "user/mysql"
end
end
```