Merge "Use a single configuration file for specifying docker containers."
[apex-tripleo-heat-templates.git] / docker / services / swift-ringbuilder.yaml
1 heat_template_version: pike
2
3 description: >
4   OpenStack Swift Ringbuilder
5
6 parameters:
7   DockerSwiftConfigImage:
8     description: The container image to use for the swift config_volume
9     type: string
10   ServiceData:
11     default: {}
12     description: Dictionary packing service data
13     type: json
14   ServiceNetMap:
15     default: {}
16     description: Mapping of service_name -> network name. Typically set
17                  via parameter_defaults in the resource registry.  This
18                  mapping overrides those in ServiceNetMapDefaults.
19     type: json
20   DefaultPasswords:
21     default: {}
22     type: json
23   RoleName:
24     default: ''
25     description: Role name on which the service is applied
26     type: string
27   RoleParameters:
28     default: {}
29     description: Parameters specific to the role
30     type: json
31   EndpointMap:
32     default: {}
33     description: Mapping of service endpoint -> protocol. Typically set
34                  via parameter_defaults in the resource registry.
35     type: json
36   SwiftMinPartHours:
37     type: number
38     default: 1
39     description: The minimum time (in hours) before a partition in a ring can be moved following a rebalance.
40   SwiftPartPower:
41     default: 10
42     description: Partition Power to use when building Swift rings
43     type: number
44   SwiftRingBuild:
45     default: true
46     description: Whether to manage Swift rings or not
47     type: boolean
48   SwiftReplicas:
49     type: number
50     default: 3
51     description: How many replicas to use in the swift rings.
52   SwiftRawDisks:
53     default: {}
54     description: 'A hash of additional raw devices to use as Swift backend (eg. {sdb: {}})'
55     type: json
56   SwiftUseLocalDir:
57     default: true
58     description: 'Use a local directory for Swift storage services when building rings'
59     type: boolean
60   SwiftRingGetTempurl:
61     default: ''
62     description: A temporary Swift URL to download rings from.
63     type: string
64   SwiftRingPutTempurl:
65     default: ''
66     description: A temporary Swift URL to upload rings to.
67     type: string
68
69 resources:
70
71   SwiftRingbuilderBase:
72     type: ../../puppet/services/swift-ringbuilder.yaml
73     properties:
74       EndpointMap: {get_param: EndpointMap}
75       ServiceData: {get_param: ServiceData}
76       ServiceNetMap: {get_param: ServiceNetMap}
77       DefaultPasswords: {get_param: DefaultPasswords}
78       RoleName: {get_param: RoleName}
79       RoleParameters: {get_param: RoleParameters}
80
81 outputs:
82   role_data:
83     description: Role data for Swift Ringbuilder configuration in containers.
84     value:
85       service_name: {get_attr: [SwiftRingbuilderBase, role_data, service_name]}
86       config_settings:
87         map_merge:
88           - {get_attr: [SwiftRingbuilderBase, role_data, config_settings]}
89           - tripleo::profile::base::swift::ringbuilder:skip_consistency_check: true
90       step_config: &step_config
91         get_attr: [SwiftRingbuilderBase, role_data, step_config]
92       service_config_settings: {get_attr: [SwiftRingbuilderBase, role_data, service_config_settings]}
93       # BEGIN DOCKER SETTINGS
94       puppet_config:
95         config_volume: 'swift'
96         puppet_tags: exec,fetch_swift_ring_tarball,extract_swift_ring_tarball,ring_object_device,swift::ringbuilder::create,tripleo::profile::base::swift::add_devices,swift::ringbuilder::rebalance,create_swift_ring_tarball,upload_swift_ring_tarball
97         step_config: *step_config
98         config_image: {get_param: DockerSwiftConfigImage}
99       kolla_config: {}
100       docker_config: {}