fuel-library/deployment/puppet/glance/manifests/policy.pp
Denis Egorenko e1d3ab1cae Sync glance module with upstream
master commit: 646a6cd15f2c358c6fde25dbb795615f45913d96

Fuel-CI: disable
Partially implements: blueprint upgrade-openstack-puppet-modules

Change-Id: Ifa9e699e4165f254664a9f6272adcc5b72e41cf8
2015-07-07 12:51:02 +00:00

40 lines
804 B
Puppet

# == Class: glance::policy
#
# Configure the glance policies
#
# === Parameters
#
# [*policies*]
# (optional) Set of policies to configure for glance
# Example :
# {
# 'glance-context_is_admin' => {
# 'key' => 'context_is_admin',
# 'value' => 'true'
# },
# 'glance-default' => {
# 'key' => 'default',
# 'value' => 'rule:admin_or_owner'
# }
# }
# Defaults to empty hash.
#
# [*policy_path*]
# (optional) Path to the glance policy.json file
# Defaults to /etc/glance/policy.json
#
class glance::policy (
$policies = {},
$policy_path = '/etc/glance/policy.json',
) {
validate_hash($policies)
Openstacklib::Policy::Base {
file_path => $policy_path,
}
create_resources('openstacklib::policy::base', $policies)
}