Skip to content

Commit

Permalink
Merge pull request #172 from mterzo/apache_vhost
Browse files Browse the repository at this point in the history
Apache vhost testing
  • Loading branch information
bastelfreak authored Mar 22, 2017
2 parents 8bb5cff + f63a2d4 commit 1988f2a
Show file tree
Hide file tree
Showing 3 changed files with 54 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .fixtures.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
fixtures:
repositories:
stdlib: "git://github.com/puppetlabs/puppetlabs-stdlib.git"
concat: "git://github.com/puppetlabs/puppetlabs-concat.git"
vcsrepo: "git://github.com/puppetlabs/puppetlabs-vcsrepo.git"
python: "git://github.com/stankevich/puppet-python.git"
epel: "git://github.com/stahnma/puppet-module-epel.git"
apache: 'git://github.com/puppetlabs/puppetlabs-apache.git'
symlinks:
puppetboard: "#{source_dir}"
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ Installation
Dependencies
------------

Note Oracle linux 5 on puppet versions 4.6.0 to 4.7.1 has pip package problem
which will cause an error trying to install puppetboard.

Note that this module no longer explicitly requires the puppetlabs apache module. If you want to use the apache functionality of this module you will have to specify that the apache module is installed with:


Expand Down Expand Up @@ -104,6 +107,16 @@ class { 'puppetboard':
}
```


Disable SELinux
-----
```puppet
class { 'puppetboard':
manage_selinux => false,
}
```


### Apache

If you want puppetboard accessible through Apache and you're able to use the
Expand Down
39 changes: 39 additions & 0 deletions spec/classes/vhost_spec.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
require 'spec_helper'

describe 'puppetboard::apache::vhost' do
describe 'default params' do
let :params do
{
'vhost_name' => 'puppetboard.local',
'port' => 80
}
end
let(:pre_condition) do
[
'class { "apache": default_vhost => false, default_mods => false, vhost_enable_dir => "/etc/apache2/sites-enabled"}',
'class { "apache::mod::wsgi": }'
]
end
on_supported_os.each do |os, facts|
let :facts do
facts
end
context "on #{os}" do
it { is_expected.to contain_class('puppetboard::apache::vhost') }
it { is_expected.to contain_file('/srv/puppetboard/puppetboard/wsgi.py') }
it do
is_expected.to contain_apache__vhost('puppetboard.local').with(
'ensure' => 'present',
'port' => 80
).that_requires('File[/srv/puppetboard/puppetboard/wsgi.py]')
end
it do
is_expected.to contain_concat('25-puppetboard.local.conf').with(
'ensure' => 'present',
'path' => '/etc/apache2/sites-available/25-puppetboard.local.conf'
)
end
end
end
end
end

0 comments on commit 1988f2a

Please sign in to comment.