Default manifest
Finally, we need to pull these modules together, and install them when our machine is provisioned. To do this, we simply add the following modules to our vagrant.pp
manifest file in the provision/manifests
folder.
Installing Nginx and PHP
We need to include our nginx
class and optionally provide a filename for the configuration file; if we don't provide one, the default will be used:
class { 'nginx': file => 'default' }
Similarly for PHP, we need to include the class and in this case, pass an nginx
parameter to ensure that it installs PHP5-FPM too:
class { 'php': nginx => true }
Hostname configuration
We should tell our Vagrant virtual machine what its hostname is by adding a host resource to our manifest:
host { 'lemp-stack.local': ip => '127.0.0.1', host_aliases => 'localhost', }
E-mail sending services
Because some of our projects might involve sending e-mails, we should...