1 heat_template_version: ocata
4 OpenStack containerized Swift Storage services.
9 default: 'tripleoupstream'
11 DockerSwiftProxyImage:
13 default: 'centos-binary-swift-proxy-server:latest'
15 DockerSwiftAccountImage:
17 default: 'centos-binary-swift-account:latest'
19 DockerSwiftContainerImage:
21 default: 'centos-binary-swift-container:latest'
23 DockerSwiftObjectImage:
25 default: 'centos-binary-swift-object:latest'
29 description: Mapping of service endpoint -> protocol. Typically set
30 via parameter_defaults in the resource registry.
37 description: Mapping of service_name -> network name. Typically set
38 via parameter_defaults in the resource registry. This
39 mapping overrides those in ServiceNetMapDefaults.
45 type: ../../puppet/services/swift-storage.yaml
47 EndpointMap: {get_param: EndpointMap}
48 ServiceNetMap: {get_param: ServiceNetMap}
49 DefaultPasswords: {get_param: DefaultPasswords}
53 description: Role data for the swift storage services.
55 service_name: {get_attr: [SwiftStorageBase, role_data, service_name]}
56 config_settings: {get_attr: [SwiftStorageBase, role_data, config_settings]}
57 step_config: &step_config
58 get_attr: [SwiftStorageBase, role_data, step_config]
59 service_config_settings: {get_attr: [SwiftStorageBase, role_data, service_config_settings]}
60 # BEGIN DOCKER SETTINGS
63 puppet_tags: swift_config,swift_container_config,swift_container_sync_realms_config,swift_account_config,swift_object_config,swift_object_expirer_config
64 step_config: *step_config
65 config_image: &swift_proxy_image
68 - [ {get_param: DockerNamespace}, {get_param: DockerSwiftProxyImage} ]
70 /var/lib/kolla/config_files/swift_account_auditor.json:
71 command: /usr/bin/swift-account-auditor /etc/swift/account-server.conf
72 /var/lib/kolla/config_files/swift_account_reaper.json:
73 command: /usr/bin/swift-account-reaper /etc/swift/account-server.conf
74 /var/lib/kolla/config_files/swift_account_replicator.json:
75 command: /usr/bin/swift-account-replicator /etc/swift/account-server.conf
76 /var/lib/kolla/config_files/swift_account_server.json:
77 command: /usr/bin/swift-account-server /etc/swift/account-server.conf
78 /var/lib/kolla/config_files/swift_container_auditor.json:
79 command: /usr/bin/swift-container-auditor /etc/swift/container-server.conf
80 /var/lib/kolla/config_files/swift_container_replicator.json:
81 command: /usr/bin/swift-container-replicator /etc/swift/container-server.conf
82 /var/lib/kolla/config_files/swift_container_updater.json:
83 command: /usr/bin/swift-container-updater /etc/swift/container-server.conf
84 /var/lib/kolla/config_files/swift_container_server.json:
85 command: /usr/bin/swift-container-server /etc/swift/container-server.conf
86 /var/lib/kolla/config_files/swift_object_auditor.json:
87 command: /usr/bin/swift-object-auditor /etc/swift/object-server.conf
88 /var/lib/kolla/config_files/swift_object_expirer.json:
89 command: /usr/bin/swift-object-expirer /etc/swift/object-expirer.conf
90 /var/lib/kolla/config_files/swift_object_replicator.json:
91 command: /usr/bin/swift-object-replicator /etc/swift/object-server.conf
92 /var/lib/kolla/config_files/swift_object_updater.json:
93 command: /usr/bin/swift-object-updater /etc/swift/object-server.conf
94 /var/lib/kolla/config_files/swift_object_server.json:
95 command: /usr/bin/swift-object-server /etc/swift/object-server.conf
98 # The puppet config sets this up but we don't have a way to mount the named
99 # volume during the configuration stage. We just need to create this
100 # directory and make sure it's owned by swift.
102 image: &swift_account_image
105 - [ {get_param: DockerNamespace}, {get_param: DockerSwiftAccountImage} ]
107 command: ['chown', '-R', 'swift:', '/srv/node']
109 - /srv/node:/srv/node
111 swift_account_auditor:
112 image: *swift_account_image
117 - /var/lib/kolla/config_files/swift_account_auditor.json:/var/lib/kolla/config_files/config.json:ro
118 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
119 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
120 - /etc/hosts:/etc/hosts:ro
121 - /etc/localtime:/etc/localtime:ro
123 - /srv/node:/srv/node
125 environment: &kolla_env
126 - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS
127 swift_account_reaper:
128 image: *swift_account_image
133 - /var/lib/kolla/config_files/swift_account_reaper.json:/var/lib/kolla/config_files/config.json:ro
134 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
135 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
136 - /etc/hosts:/etc/hosts:ro
137 - /etc/localtime:/etc/localtime:ro
139 - /srv/node:/srv/node
141 environment: *kolla_env
142 swift_account_replicator:
143 image: *swift_account_image
148 - /var/lib/kolla/config_files/swift_account_replicator.json:/var/lib/kolla/config_files/config.json:ro
149 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
150 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
151 - /etc/hosts:/etc/hosts:ro
152 - /etc/localtime:/etc/localtime:ro
154 - /srv/node:/srv/node
156 environment: *kolla_env
157 swift_account_server:
158 image: *swift_account_image
163 - /var/lib/kolla/config_files/swift_account_server.json:/var/lib/kolla/config_files/config.json:ro
164 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
165 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
166 - /etc/hosts:/etc/hosts:ro
167 - /etc/localtime:/etc/localtime:ro
169 - /srv/node:/srv/node
171 environment: *kolla_env
172 swift_container_auditor:
173 image: &swift_container_image
176 - [ {get_param: DockerNamespace}, {get_param: DockerSwiftContainerImage} ]
181 - /var/lib/kolla/config_files/swift_container_auditor.json:/var/lib/kolla/config_files/config.json:ro
182 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
183 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
184 - /etc/hosts:/etc/hosts:ro
185 - /etc/localtime:/etc/localtime:ro
187 - /srv/node:/srv/node
189 environment: *kolla_env
190 swift_container_replicator:
191 image: *swift_container_image
196 - /var/lib/kolla/config_files/swift_container_replicator.json:/var/lib/kolla/config_files/config.json:ro
197 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
198 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
199 - /etc/hosts:/etc/hosts:ro
200 - /etc/localtime:/etc/localtime:ro
202 - /srv/node:/srv/node
204 environment: *kolla_env
205 swift_container_updater:
206 image: *swift_container_image
211 - /var/lib/kolla/config_files/swift_container_updater.json:/var/lib/kolla/config_files/config.json:ro
212 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
213 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
214 - /etc/hosts:/etc/hosts:ro
215 - /etc/localtime:/etc/localtime:ro
217 - /srv/node:/srv/node
219 environment: *kolla_env
220 swift_container_server:
221 image: *swift_container_image
226 - /var/lib/kolla/config_files/swift_container_server.json:/var/lib/kolla/config_files/config.json:ro
227 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
228 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
229 - /etc/hosts:/etc/hosts:ro
230 - /etc/localtime:/etc/localtime:ro
232 - /srv/node:/srv/node
234 environment: *kolla_env
235 swift_object_auditor:
236 image: &swift_object_image
239 - [ {get_param: DockerNamespace}, {get_param: DockerSwiftObjectImage} ]
244 - /var/lib/kolla/config_files/swift_object_auditor.json:/var/lib/kolla/config_files/config.json:ro
245 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
246 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
247 - /etc/hosts:/etc/hosts:ro
248 - /etc/localtime:/etc/localtime:ro
250 - /srv/node:/srv/node
252 environment: *kolla_env
253 swift_object_expirer:
254 image: *swift_proxy_image
259 - /var/lib/kolla/config_files/swift_object_expirer.json:/var/lib/kolla/config_files/config.json:ro
260 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
261 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
262 - /etc/hosts:/etc/hosts:ro
263 - /etc/localtime:/etc/localtime:ro
265 - /srv/node:/srv/node
267 environment: *kolla_env
268 swift_object_replicator:
269 image: *swift_object_image
274 - /var/lib/kolla/config_files/swift_object_replicator.json:/var/lib/kolla/config_files/config.json:ro
275 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
276 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
277 - /etc/hosts:/etc/hosts:ro
278 - /etc/localtime:/etc/localtime:ro
280 - /srv/node:/srv/node
282 environment: *kolla_env
283 swift_object_updater:
284 image: *swift_object_image
289 - /var/lib/kolla/config_files/swift_object_updater.json:/var/lib/kolla/config_files/config.json:ro
290 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
291 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
292 - /etc/hosts:/etc/hosts:ro
293 - /etc/localtime:/etc/localtime:ro
295 - /srv/node:/srv/node
297 environment: *kolla_env
299 image: *swift_object_image
304 - /var/lib/kolla/config_files/swift_object_server.json:/var/lib/kolla/config_files/config.json:ro
305 - /var/lib/config-data/swift/:/var/lib/kolla/config_files/src:ro
306 - /var/lib/config-data/swift/etc/swift:/etc/swift:rw
307 - /etc/hosts:/etc/hosts:ro
308 - /etc/localtime:/etc/localtime:ro
310 - /srv/node:/srv/node
312 environment: *kolla_env
314 - name: create /srv/node
319 - name: Stop and disable swift storage services
321 service: name={{ item }} state=stopped enabled=no
323 - openstack-swift-account-auditor
324 - openstack-swift-account-reaper
325 - openstack-swift-account-replicator
326 - openstack-swift-account
327 - openstack-swift-container-auditor
328 - openstack-swift-container-replicator
329 - openstack-swift-container-updater
330 - openstack-swift-container
331 - openstack-swift-object-auditor
332 - openstack-swift-object-replicator
333 - openstack-swift-object-updater
334 - openstack-swift-object