system-config/modules/openstack_project/manifests/puppetboard.pp
Spencer Krum 101e58991c Further changes to bring puppetboard online
Use inherits keyword to bring puppetboard::params into scope
Use 2>&1 in install_modules to silence warnings
Set puppetdb class to open port 80 when puppetboard is used
Remove inherits from params check from puppet lint

Change-Id: I75fc35542e9f2641bcab613d7e1aef83d9300217
2014-03-22 12:54:38 -07:00

45 lines
974 B
Puppet

# Class to configure puppetboard on a node.
# This will only work on the puppetdb server for now
class openstack_project::puppetboard(
$basedir = $::puppetboard::params::basedir,
$user = $::puppetboard::params::user,
$group = $::puppetboard::params::group,
$port = '80',
) inherits ::puppetboard::params {
include apache
class { 'apache::mod::wsgi': }
class { '::puppetboard':
enable_query => 'False', # This being a python false
}
$docroot = "${basedir}/puppetboard"
# Template Uses:
# - $basedir
#
file { "${docroot}/wsgi.py":
ensure => present,
content => template('puppetboard/wsgi.py.erb'),
owner => $user,
group => $group,
require => User[$user],
}
# Template Uses:
# - $docroot
# - $user
# - $group
# - $port
#
apache::vhost { $::fqdn:
port => 80,
docroot => $docroot,
priority => '50',
template => 'openstack_project/puppetboard/puppetboard.vhost.erb',
}
}