Using Modules Commands - mcuyar/station GitHub Wiki
Commands are inline bash scripts. To run a command supply the commands
parameter to your config file
with a single command or an array of commands.
Single
commands: 'ntpdate ntp.ubuntu.com'
Multiple
commands:
- 'mkdir world'
- 'touch world/hello.txt'
Global Commands
Global commands are set to run from the vagrant home directory ~/
Site Commands
Site commands are run from the site root directory /var/www/path/to/site/root
Site's differ from global commands by offering the option of three stages for running commands
commands:
install:
- 'composer install --prefer-source'
- 'git fetch origin'
update:
- 'composer update'
always:
- 'echo \"updating site\"'
install: Will run the first time a vagrant provision
is run with the site included in the config file (only for git installs at the moment).
update: Commands will only run after the initial install provision has run
always: Commands will always run