-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
apache::balancer: Add a target parameter to write to a custom path
Thit commits implements a target parameter to the apache::balancer definition to specify a different configuration path if needed (e.g with a different suffix or in a different location).
- Loading branch information
1 parent
0fca822
commit b2bc76f
Showing
4 changed files
with
86 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
require 'spec_helper' | ||
|
||
describe 'apache::balancer', :type => :define do | ||
let :pre_condition do | ||
'include apache' | ||
end | ||
let :facts do | ||
{ | ||
:osfamily => 'Debian', | ||
:operatingsystem => 'Debian', | ||
:operatingsystemrelease => '6', | ||
:lsbdistcodename => 'squeeze', | ||
:id => 'root', | ||
:concat_basedir => '/dne', | ||
:path => '/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin', | ||
:kernel => 'Linux', | ||
:is_pe => false, | ||
} | ||
end | ||
describe "accept a target parameter and use it" do | ||
let :title do | ||
'myapp' | ||
end | ||
let :params do | ||
{ | ||
:target => '/tmp/myapp.conf' | ||
} | ||
end | ||
it { should contain_concat('apache_balancer_myapp').with({ | ||
:path => "/tmp/myapp.conf", | ||
})} | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters