pegasuscommerce / vagrant_transient
Vagrant Transient - application to power down all your Vagrant Instances
This package's canonical repository appears to be gone and the package has been frozen as a result.
Installs: 102
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Type:application
Requires
- php: >=5.3
- monolog/monolog: 1.23.0
- symfony/console: >=2.7
Requires (Dev)
- kherge/box: ~2.5
- phpspec/phpspec: ~2.0
- squizlabs/php_codesniffer: 2.*
This package is not auto-updated.
Last update: 2023-08-13 02:47:47 UTC
README
This application stops developers having to navigate to each project and check the Vagrant instance is down before starting their new Vagrant instance.
When configured within a VagrantFile of every project using Vagrant this application will shutdown all Vagrant instances before starting the current instance.
Please note that this isn't a plugin for Vagrant.
Installation
Ensure you have downloaded and installed Vagrant 1.2+ from the Vagrant downloads page.
Tagrant Transient is designed to work with the vagrant-triggers plugin.
Installation is performed in the prescribed manner for Vagrant plugins:
vagrant plugin install vagrant-triggers
Once this is installed Vagrant Transient can be done a couple of ways:
- by downloading the vagrant_transient.phar file and adding it into /usr/bin
- Add "pegasuscommerce/vagrant_transient" to composer using the current version
Once this has been done environments in Vagrant Transient are automatically created, destroyed and shutdown in Vagrant
Using Vagrant Transient
Note that Vagrant Transient will manage an instance once 'vagrant up' has been called or '{vagrant_transient} create' has been called from a directory with a Vagrantfile in it. Only then will an environment be managed by Vagrant Transient.
Once installed you can use it to manage Vagrant instances through Vagrant or just via the terminal using the vagrant_transient.phar, bin/vagrant_transient to create, destroy etc.
###Adding the triggers to Vagrant ####Composer method Open your Vagrantfile and add the following:
config.trigger.before :up do run "bin/vagranttransient dc" end config.trigger.after :destroy do run "bin/vagranttransient destroy" end
####vagrant_transient.phar method
config.trigger.before :up do run "vagrant_transient.phar dc" end config.trigger.after :destroy do run "vagrant_transient.phar destroy" end
This will call 'vagrant_transient.phar dc' when 'vagrant up' is called and 'vagrant_transient.phar destroy' when 'vagrant destroy' is called. Creating and destroying vagrant-transient environments automatically.
###Commands which are available
- clean Cleans all store environments
- create Adds environment to storage
- dc Shuts down all vagrants before creating the current environment
- destory Removed environment from storage
- down Shuts down all vagrant instances
- migrate Migrates config from storage to storage
- version Returns the version of this application
- environments Returns a list of the current environments in Vagrant Transient
##Other
Feel free to report bugs, fork etc. If you want to contribute just create a pull request when you're ready.