end
def self.instances
- if not resource[:os_cacert].nil?
- resource_args = ['project', 'list', nil, nil, '--long', '--os-cacert', resource[:os_cacert]]
- else
- resource_args = ['project', 'list', nil, nil, '--long']
- end
- list = request(resource_args)
+ list = request('project', 'list', nil, nil, '--long')
list.collect do |project|
new(
:name => project[:name],
end
def instances
- if not resource[:os_cacert].nil?
- resource_args = ['project', 'list', nil, resource[:auth], '--long', '--os-cacert', resource[:os_cacert]]
- else
- resource_args = ['project', 'list', nil, resource[:auth], '--long']
- end
- instances = request(resource_args)
+ instances = request('project', 'list', nil, resource[:auth], '--long')
instances.collect do |project|
{
:name => project[:name],
newvalues(/\w+/)
end
- newparam(:os_cacert) do
- desc 'Parse os_cacert.'
- end
-
newproperty(:enabled) do
desc 'Whether the tenant should be enabled. Defaults to true.'
newvalues(/(t|T)rue/, /(f|F)alse/, true, false )
$service_tenant_desc = 'Tenant for the openstack services',
$configure_user = true,
$configure_user_role = true,
- $validate_cacert = undef,
) {
keystone_tenant { $service_tenant:
ensure => present,
enabled => true,
description => $service_tenant_desc,
- os_cacert => $validate_cacert,
}
keystone_tenant { $admin_tenant:
ensure => present,
enabled => true,
description => $admin_tenant_desc,
- os_cacert => $validate_cacert,
}
keystone_role { 'admin':
ensure => present,
class { '::keystone::roles::admin':
email => 'test@puppetlabs.com',
password => $admin_pass,
- validate_cacert => '/etc/ssl/debian/certs/ca.crt',
}
class { '::keystone::endpoint':
public_url => 'https://openstack.bm.debian.org:5000/',