For test purposes I wanted to setup puppet and deploy apache on Ubuntu 16.4 puppet master using puppet without bothering with using nodes by using the following steps:
$ wget https://apt.puppetlabs.com/puppet5-release-xenial.deb
Install the package by running:
$ dpkg –i puppet5-release-xenial.deb
Update package list
$ apt-get update
Install puppet server
$ sudo apt-get install puppetserver
On our Puppet server, install the puppetlabs-apache module:
$ sudo puppet module install puppetlabs-apache
From within the manifests directory, an init.pp class needs to be created /etc/puppet/modules/apache/manifests/init.pp
class apache2 {
package {'apache2':
ensure => 'present',
}
}
To try to install the apache package I used:
$ sudo puppet apply init.pp
I then got the following:
Notice: Compiled catalog for osboxes.home in environment production in 0.03 seconds
Notice: Finished catalog run in 0.04 seconds
And when I check if apache is installed, it is not.
Where am I going wrong?