1 heat_template_version: pike
4 OpenStack Barbican API service configured with Puppet
9 description: Mapping of service_name -> network name. Typically set
10 via parameter_defaults in the resource registry. This
11 mapping overrides those in ServiceNetMapDefaults.
18 description: Role name on which the service is applied
22 description: Parameters specific to the role
26 description: Mapping of service endpoint -> protocol. Typically set
27 via parameter_defaults in the resource registry.
30 description: The password for the barbican service account.
34 description: Set the number of workers for barbican::wsgi::apache
35 default: '%{::processorcount}'
39 description: Set to True to enable debugging on all services.
43 description: Set to True to enable debugging Barbican service.
48 description: Keystone region for endpoint
51 description: Set rabbit subscriber port, change this if using SSL
56 Rabbit client subscriber parameter to specify
57 an SSL connection to the RabbitMQ host.
60 description: The password for RabbitMQ
65 description: The username for RabbitMQ
72 A hash of policies to configure for Barbican.
73 e.g. { barbican-context_is_admin: { key: context_is_admin, value: 'role:admin' } }
82 ServiceNetMap: {get_param: ServiceNetMap}
83 DefaultPasswords: {get_param: DefaultPasswords}
84 EndpointMap: {get_param: EndpointMap}
85 RoleName: {get_param: RoleName}
86 RoleParameters: {get_param: RoleParameters}
89 service_debug_unset: {equals : [{get_param: BarbicanDebug}, '']}
93 description: Role data for the Barbican API role.
95 service_name: barbican_api
98 - get_attr: [ApacheServiceBase, role_data, config_settings]
99 - barbican::keystone::authtoken::password: {get_param: BarbicanPassword}
100 barbican::keystone::authtoken::auth_uri: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]}
101 barbican::keystone::authtoken::auth_url: { get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]}
102 barbican::keystone::authtoken::project_name: 'service'
103 barbican::policy::policies: {get_param: BarbicanPolicies}
104 barbican::api::host_href: {get_param: [EndpointMap, BarbicanPublic, uri]}
105 barbican::api::db_auto_create: false
106 barbican::api::enabled_certificate_plugins: ['simple_certificate']
107 barbican::api::logging::debug:
109 - service_debug_unset
110 - {get_param: Debug }
111 - {get_param: BarbicanDebug }
112 barbican::api::rabbit_use_ssl: {get_param: RabbitClientUseSSL}
113 barbican::api::rabbit_userid: {get_param: RabbitUserName}
114 barbican::api::rabbit_password: {get_param: RabbitPassword}
115 barbican::api::rabbit_port: {get_param: RabbitClientPort}
116 barbican::api::rabbit_heartbeat_timeout_threshold: 60
117 barbican::api::service_name: 'httpd'
118 barbican::wsgi::apache::bind_host: {get_param: [ServiceNetMap, BarbicanApiNetwork]}
119 barbican::wsgi::apache::ssl: {get_param: EnableInternalTLS}
120 barbican::wsgi::apache::workers: {get_param: BarbicanWorkers}
121 barbican::wsgi::apache::servername:
124 "%{hiera('fqdn_$NETWORK')}"
126 $NETWORK: {get_param: [ServiceNetMap, BarbicanApiNetwork]}
127 barbican::db::database_connection:
129 scheme: {get_param: [EndpointMap, MysqlInternal, protocol]}
131 password: {get_param: BarbicanPassword}
132 host: {get_param: [EndpointMap, MysqlInternal, host]}
135 read_default_file: /etc/my.cnf.d/tripleo.cnf
136 read_default_group: tripleo
137 tripleo.barbican_api.firewall_rules:
143 include ::tripleo::profile::base::barbican::api
144 service_config_settings:
146 barbican::db::mysql::password: {get_param: BarbicanPassword}
147 barbican::db::mysql::user: barbican
148 barbican::db::mysql::host: {get_param: [EndpointMap, MysqlInternal, host_nobrackets]}
149 barbican::db::mysql::dbname: barbican
150 barbican::db::mysql::allowed_hosts:
152 - "%{hiera('mysql_bind_host')}"
154 barbican::keystone::auth::public_url: {get_param: [EndpointMap, BarbicanPublic, uri]}
155 barbican::keystone::auth::internal_url: {get_param: [EndpointMap, BarbicanInternal, uri]}
156 barbican::keystone::auth::admin_url: {get_param: [EndpointMap, BarbicanAdmin, uri]}
157 barbican::keystone::auth::password: {get_param: BarbicanPassword}
158 barbican::keystone::auth::region: {get_param: KeystoneRegion}
159 barbican::keystone::auth::tenant: 'service'
161 nova::compute::keymgr_api_class: >
162 castellan.key_manager.barbican_key_manager.BarbicanKeyManager
163 nova::compute::barbican_endpoint:
164 get_param: [EndpointMap, BarbicanInternal, uri]
165 nova::compute::barbican_auth_endpoint:
166 get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]
168 cinder::api::keymgr_api_class: >
169 castellan.key_manager.barbican_key_manager.BarbicanKeyManager
170 cinder::api::keymgr_encryption_api_url:
171 get_param: [EndpointMap, BarbicanInternal, uri]
172 cinder::api::keymgr_encryption_auth_url:
173 get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]
175 get_attr: [ApacheServiceBase, role_data, metadata_settings]
178 expression: $.data.apache_upgrade + $.data.barbican_api_upgrade
181 get_attr: [ApacheServiceBase, role_data, upgrade_tasks]
182 barbican_api_upgrade:
183 - name: Check if barbican_api is deployed
184 command: systemctl is-enabled openstack-barbican-api
187 register: barbican_api_enabled
188 - name: "PreUpgrade step0,validation: Check service openstack-barbican-api is running"
189 shell: /usr/bin/systemctl show 'openstack-barbican-api' --property ActiveState | grep '\bactive\b'
190 when: barbican_api_enabled.rc == 0
191 tags: step0,validation
192 - name: Install openstack-barbican-api package if it was disabled
194 yum: name=openstack-barbican-api state=latest
195 when: barbican_api_enabled.rc != 0