Merge "Containerized Sensu client"
[apex-tripleo-heat-templates.git] / puppet / services / gnocchi-base.yaml
1 heat_template_version: pike
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   DefaultPasswords:
14     default: {}
15     type: json
16   RoleName:
17     default: ''
18     description: Role name on which the service is applied
19     type: string
20   RoleParameters:
21     default: {}
22     description: Parameters specific to the role
23     type: json
24   EndpointMap:
25     default: {}
26     description: Mapping of service endpoint -> protocol. Typically set
27                  via parameter_defaults in the resource registry.
28     type: json
29   GnocchiIndexerBackend:
30     default: 'mysql'
31     description: The short name of the Gnocchi indexer backend to use.
32     type: string
33   MetricProcessingDelay:
34     default: 30
35     description: Delay between processing metrics.
36     type: number
37   NumberOfStorageSacks:
38     default: 128
39     description: Number of storage sacks to create.
40     type: number
41   GnocchiPassword:
42     description: The password for the gnocchi service and db account.
43     type: string
44     hidden: true
45   GnocchiRbdPoolName:
46     default: metrics
47     type: string
48   CephClientUserName:
49     default: openstack
50     type: string
51   RedisPassword:
52     description: The password for the redis service account.
53     type: string
54     hidden: true
55   Debug:
56     type: string
57     default: ''
58     description: Set to True to enable debugging on all services.
59   GnocchiDebug:
60     default: ''
61     description: Set to True to enable debugging Gnocchi services.
62     type: string
63
64 conditions:
65   service_debug_unset: {equals : [{get_param: GnocchiDebug}, '']}
66
67 outputs:
68   aux_parameters:
69     description: Additional parameters referenced outside the base file
70     value:
71       gnocchi_indexer_backend: {get_param: GnocchiIndexerBackend}
72   role_data:
73     description: Shared role data for the Heat services.
74     value:
75       service_name: gnocchi_base
76       config_settings:
77         #Gnocchi engine
78         gnocchi_redis_password: {get_param: RedisPassword}
79         gnocchi::debug:
80           if:
81           - service_debug_unset
82           - {get_param: Debug }
83           - {get_param: GnocchiDebug }
84         gnocchi::db::database_connection:
85           make_url:
86             scheme: {get_param: [EndpointMap, MysqlInternal, protocol]}
87             username: gnocchi
88             password: {get_param: GnocchiPassword}
89             host: {get_param: [EndpointMap, MysqlInternal, host]}
90             path: /gnocchi
91             query:
92               read_default_file: /etc/my.cnf.d/tripleo.cnf
93               read_default_group: tripleo
94         gnocchi::db::sync::extra_opts:
95           str_replace:
96             template: " --sacks-number NUM_SACKS"
97             params:
98               NUM_SACKS: {get_param: NumberOfStorageSacks}
99         gnocchi::storage::metric_processing_delay: {get_param: MetricProcessingDelay}
100         gnocchi::storage::swift::swift_user: 'service:gnocchi'
101         gnocchi::storage::swift::swift_auth_version: 3
102         gnocchi::storage::swift::swift_key: {get_param: GnocchiPassword}
103         gnocchi::storage::swift::swift_authurl: {get_param: [EndpointMap, KeystoneV3Internal, uri]}
104         gnocchi::storage::ceph::ceph_pool: {get_param: GnocchiRbdPoolName}
105         gnocchi::storage::ceph::ceph_username: {get_param: CephClientUserName}
106         gnocchi::storage::ceph::ceph_keyring:
107           list_join:
108           - '.'
109           - - '/etc/ceph/ceph'
110             - 'client'
111             - {get_param: CephClientUserName}
112             - 'keyring'
113         #Gnocchi statsd
114         gnocchi::statsd::resource_id: '0a8b55df-f90f-491c-8cb9-7cdecec6fc26'
115         gnocchi::statsd::user_id: '27c0d3f8-e7ee-42f0-8317-72237d1c5ae3'
116         gnocchi::statsd::project_id: '6c38cd8d-099a-4cb2-aecf-17be688e8616'
117         gnocchi::statsd::flush_delay: 10
118         gnocchi::statsd::archive_policy_name: 'low'