-- sources used to build nginx module:
http://nginx.org/en/docs/beginners_guide.html
CentOS/RedHat 6,7 Ubuntu 12,14
PE 3.8 and greater
clone this repository to your modules directory,
To change specific parameters like binding port # or user names, open up /manifests/params.pp and change the values there
node YourNode { include nginx }
nodeName.yaml classes:
in order to serve up the latest 'index.html' file, you need to install the puppetlabs-vcsrepo module on PE Master, run 'puppet module install puppetlabs-vcsrepo'
VI the /nginx/manifests/params.pp and update your $modulepath to point to your production modules
$modulepath = "/etc/puppetlabs/code/environments/production/modules"
on PE Master, run "puppet apply [modulepath]/nginx/tests/pull_repo.pp"
This will create a cron setting on your PE Master, to pull in the latest index.html from remote git repo. Its set to a default of 15 min, to adjust it open the params.pp and update the value for $git_sync_min
to check cron settings on your PE Master, run 'crontab -l' you should see a setting like this:
# Puppet Name: pullremote
*/15 /usr/local/bin/puppet apply /etc/puppetlabs/code/environments/production/modules/nginx/tests/pull_remote.pp
Your '/nginx/files/repo/index.html' file will now be updated directly from Git every 15 min.