2110250532e384fc2f56169a0fe49e0d860510c3
[apex-tripleo-heat-templates.git] / docker / services / swift-ringbuilder.yaml
1 heat_template_version: ocata
2
3 description: >
4   OpenStack Swift Ringbuilder
5
6 parameters:
7   DockerNamespace:
8     description: namespace
9     default: 'tripleoupstream'
10     type: string
11   DockerSwiftProxyImage:
12     description: image
13     default: 'centos-binary-swift-proxy-server:latest'
14     type: string
15   ServiceNetMap:
16     default: {}
17     description: Mapping of service_name -> network name. Typically set
18                  via parameter_defaults in the resource registry.  This
19                  mapping overrides those in ServiceNetMapDefaults.
20     type: json
21   DefaultPasswords:
22     default: {}
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   SwiftMinPartHours:
30     type: number
31     default: 1
32     description: The minimum time (in hours) before a partition in a ring can be moved following a rebalance.
33   SwiftPartPower:
34     default: 10
35     description: Partition Power to use when building Swift rings
36     type: number
37   SwiftRingBuild:
38     default: true
39     description: Whether to manage Swift rings or not
40     type: boolean
41   SwiftReplicas:
42     type: number
43     default: 3
44     description: How many replicas to use in the swift rings.
45   SwiftRawDisks:
46     default: {}
47     description: 'A hash of additional raw devices to use as Swift backend (eg. {sdb: {}})'
48     type: json
49   SwiftUseLocalDir:
50     default: true
51     description: 'Use a local directory for Swift storage services when building rings'
52     type: boolean
53
54 resources:
55
56   SwiftRingbuilderBase:
57     type: ../../puppet/services/swift-ringbuilder.yaml
58     properties:
59       EndpointMap: {get_param: EndpointMap}
60       ServiceNetMap: {get_param: ServiceNetMap}
61       DefaultPasswords: {get_param: DefaultPasswords}
62
63 outputs:
64   role_data:
65     description: Role data for Swift Ringbuilder configuration in containers.
66     value:
67       service_name: {get_attr: [SwiftRingbuilderBase, role_data, service_name]}
68       config_settings: {get_attr: [SwiftRingbuilderBase, role_data, config_settings]}
69       step_config: &step_config
70         get_attr: [SwiftRingbuilderBase, role_data, step_config]
71       service_config_settings: {get_attr: [SwiftRingbuilderBase, role_data, service_config_settings]}
72       # BEGIN DOCKER SETTINGS
73       puppet_config:
74         config_volume: 'swift'
75         puppet_tags: exec,ring_object_device,swift::ringbuilder::create,tripleo::profile::base::swift::add_devices,swift::ringbuilder::rebalance
76         step_config: *step_config
77         config_image:
78           list_join:
79             - '/'
80             - [ {get_param: DockerNamespace}, {get_param: DockerSwiftProxyImage} ]
81       kolla_config: {}
82       docker_config: {}