Enable IPA client install

The puppet-ipaclient package is available in delorean.
Therefore, we can enable the requires directive that will
perform the ipa-client-install.

Depends-On: I8e9bd4ed859cc438a309d9a00dd278c65dbb822d
Change-Id: I6732af38d0f815d29cf4fa65149a54c8fb2c6527
This commit is contained in:
Ade Lee
2017-01-10 23:55:53 -05:00
parent d662695456
commit aa493b34c8
3 changed files with 34 additions and 11 deletions

View File

@@ -123,12 +123,9 @@ class nova::metadata::novajoin::api (
}
} # Case $::osfamily
# Keep this commented out until puppet-ipaclient is available
# This will invoke ipa-client-install
#
# if $enable_ipa_client_install {
# require ::ipaclient
# }
if $enable_ipa_client_install {
require ::ipaclient
}
package { 'python-novajoin':
ensure => $ensure_package,

View File

@@ -55,6 +55,10 @@
"name": "duritong/sysctl",
"version_requirement": ">=0.0.1 <1.0.0"
},
{
"name": "joshuabaird/puppet-ipaclient",
"version_requirement": ">=2.5.1"
},
{
"name": "openstack/cinder",
"version_requirement": ">=10.1.0 <11.0.0"

View File

@@ -5,9 +5,10 @@ describe 'nova::metadata::novajoin::api' do
let :facts do
@default_facts.merge(
{
:osfamily => 'RedHat',
:processorcount => '7',
:fqdn => "undercloud.example.com",
:osfamily => 'RedHat',
:processorcount => '7',
:fqdn => "undercloud.example.com",
:operatingsystemrelease => '7.0',
}
)
end
@@ -74,6 +75,10 @@ describe 'nova::metadata::novajoin::api' do
param_hash
end
let :pre_condition do
'class { "::ipaclient": password => "join_otp", }'
end
it { is_expected.to contain_service('novajoin-server').with(
'ensure' => (param_hash[:manage_service] && param_hash[:enabled]) ? 'running': 'stopped',
'enable' => param_hash[:enabled],
@@ -123,6 +128,14 @@ describe 'nova::metadata::novajoin::api' do
end
describe 'with disabled service managing' do
let :facts do
OSDefaults.get_facts({
:osfamily => 'RedHat',
:operatingsystem => 'RedHat',
:operatingsystemrelease => '7.0',
})
end
let :params do
{
:manage_service => false,
@@ -133,6 +146,10 @@ describe 'nova::metadata::novajoin::api' do
}
end
let :pre_condition do
'class { "::ipaclient": password => "join_otp", }'
end
it { is_expected.to contain_service('novajoin-server').with(
'ensure' => nil,
'enable' => false,
@@ -153,12 +170,17 @@ describe 'nova::metadata::novajoin::api' do
describe 'on RedHat platforms' do
let :facts do
OSDefaults.get_facts({
:osfamily => 'RedHat',
:operatingsystem => 'RedHat',
:osfamily => 'RedHat',
:operatingsystem => 'RedHat',
:operatingsystemrelease => '7.0',
})
end
let(:params) { default_params }
let :pre_condition do
'class { "::ipaclient": password => "join_otp", }'
end
it { is_expected.to contain_package('python-novajoin').with(
:tag => ['openstack', 'novajoin-package'],
)}