Vagrant configulation sample. Double click *.command
file to provisioning, run servers, reset database, etc.
- Install VirtualBox - easy
- Install Vagrant - very easy
- Dobule click start.command
- Wait for a few minutes...
- Access http://192.168.33.10:8080/ and you can access Rails through Nginx
Add script to provision.sh with version number(+1), and commit.
Ask team members to double click provision.command.
The provision.sh executes only the blocks with new version numbers. The version number is saved to /root/.provisioning_version
.
sandbox/bin/*.command scripts SSH login to the VM and execute sandbox/bin/local/*.command.
vagrant ssh -c '/vagrant/sandbox/bin/local/start.command'
Also, you can run sandbox/bin/local/*.command directly on OSX.
sandbox/bin/start.command starts servers using foreman
.
See Procfile to see what foreman do.
And you can foreman start
locally, if you want. Procfile works on both VM and OSX. Just double click sandbox/bin/local/start.command to start foreman.
Project root directory mounted to /vagrant
.
Frontend-engineers, designers, or editors can edit HTML, CSS, JS, templates on their local machine. Any changes can see througe VM immediately.
All configuration files should be added to the repository.
Team members fetch the configuration files, restart VM, double click provision.command if required, and all works fine!
Maintenance is not so difficult, because every members can use this sandbox on VM or OSX, in everydays development.