Merge "Pass ServiceNetMap to services"
[apex-tripleo-heat-templates.git] / puppet / services / gnocchi-api.yaml
1 heat_template_version: 2016-04-08
2
3 description: >
4   Gnocchi service configured with Puppet
5
6 parameters:
7   ServiceNetMap:
8     default: {}
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.
12     type: json
13   EndpointMap:
14     default: {}
15     description: Mapping of service endpoint -> protocol. Typically set
16                  via parameter_defaults in the resource registry.
17     type: json
18   GnocchiPassword:
19     description: The password for the gnocchi service and db account.
20     type: string
21     hidden: true
22   GnocchiBackend:
23     default: file
24     description: The short name of the Gnocchi backend to use. Should be one
25       of swift, rbd, or file
26     type: string
27     constraints:
28     - allowed_values: ['swift', 'file', 'rbd']
29   KeystoneRegion:
30     type: string
31     default: 'regionOne'
32     description: Keystone region for endpoint
33
34 resources:
35   GnocchiServiceBase:
36     type: ./gnocchi-base.yaml
37     properties:
38       ServiceNetMap: {get_param: ServiceNetMap}
39       EndpointMap: {get_param: EndpointMap}
40
41 outputs:
42   role_data:
43     description: Role data for the Gnocchi role.
44     value:
45       service_name: gnocchi_api
46       config_settings:
47         map_merge:
48           - get_attr: [GnocchiServiceBase, role_data, config_settings]
49           - tripleo.gnocchi_api.firewall_rules:
50               '129 gnocchi-api':
51                 dport:
52                   - 8041
53                   - 13041
54             gnocchi::api::enabled: true
55             gnocchi::api::manage_service: false
56             gnocchi::api::service_name: 'httpd'
57             gnocchi::keystone::auth::admin_url: { get_param: [ EndpointMap, GnocchiAdmin, uri ] }
58             gnocchi::keystone::auth::internal_url: {get_param: [EndpointMap, GnocchiInternal, uri]}
59             gnocchi::keystone::auth::password: {get_param: GnocchiPassword}
60             gnocchi::keystone::auth::public_url: { get_param: [ EndpointMap, GnocchiPublic, uri ] }
61             gnocchi::keystone::auth::region: {get_param: KeystoneRegion}
62             gnocchi::keystone::auth::tenant: 'service'
63             gnocchi::keystone::authtoken::auth_uri: {get_param: [EndpointMap, KeystoneInternal, uri]}
64             gnocchi::keystone::authtoken::auth_url: {get_param: [EndpointMap, KeystoneAdmin, uri_no_suffix]}
65             gnocchi::keystone::authtoken::password: {get_param: GnocchiPassword}
66             gnocchi::keystone::authtoken::project_name: 'service'
67             gnocchi::wsgi::apache::ssl: false
68             tripleo::profile::base::gnocchi::api::gnocchi_backend: {get_param: GnocchiBackend}
69       step_config: |
70         include ::tripleo::profile::base::gnocchi::api