I want to use Vagrant and Ansible to mirror the production environment and infrastructure locally. I have setup a Vagrant file along with each Project/Website (App1, App2, ...) I'm working on. For easier maintenance and clarity, I want to use one server gathering statsd, logs and other metrics + pulling backups.
+-----------+ +-----------+
| App1 | | Metrics |
| +-+--+ Backups |
+-----------+ | +-----------+
|
+-----------+ |
| App2 | |
| +-+
+-----------+
Since the Metrics/Backup server is not really part of the website projects, I think the best way is to introduce a dedicated "backup project" with its own Vagrant file. Now some questions/concerns regarding this setup.
- Lets say I'm working on App1. To start testing, I have
Vagrant up
on both App1 and the Metric server. Is there a better way to start them at once? - In general, is it a good idea to use vagrant for infrastructure related servers like backup, which are not essential for the website to function?
- Can I link multiple "instances" of Vagrant via private networking?