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