44ef2a3ec1
The new master branch should point now to rocky. So, HOT templates should specify that they might contain features for rocky release [1] Also, this submission updates the yaml validation to use only latest heat_version alias. There are cases in which we will need to set the version for specific templates i.e. mixed versions, so there is added a variable to assign specific templates to specific heat_version aliases, avoiding the introductions of error by bulk replacing the the old version in new releases. [1]: https://docs.openstack.org/heat/latest/template_guide/hot_spec.html#rocky Change-Id: Ib17526d9cc453516d99d4659ee5fa51a5aa7fb4b
162 lines
5.5 KiB
YAML
162 lines
5.5 KiB
YAML
heat_template_version: rocky
|
|
|
|
description: >
|
|
OpenStack Swift Storage service configured with Puppet
|
|
|
|
parameters:
|
|
ServiceData:
|
|
default: {}
|
|
description: Dictionary packing service data
|
|
type: json
|
|
ServiceNetMap:
|
|
default: {}
|
|
description: Mapping of service_name -> network name. Typically set
|
|
via parameter_defaults in the resource registry. This
|
|
mapping overrides those in ServiceNetMapDefaults.
|
|
type: json
|
|
DefaultPasswords:
|
|
default: {}
|
|
type: json
|
|
RoleName:
|
|
default: ''
|
|
description: Role name on which the service is applied
|
|
type: string
|
|
RoleParameters:
|
|
default: {}
|
|
description: Parameters specific to the role
|
|
type: json
|
|
EndpointMap:
|
|
default: {}
|
|
description: Mapping of service endpoint -> protocol. Typically set
|
|
via parameter_defaults in the resource registry.
|
|
type: json
|
|
Debug:
|
|
default: false
|
|
description: Set to True to enable debugging on all services.
|
|
type: boolean
|
|
SwiftMountCheck:
|
|
default: false
|
|
description: Value of mount_check in Swift account/container/object -server.conf
|
|
type: boolean
|
|
SwiftRawDisks:
|
|
default: {}
|
|
description: 'A hash of additional raw devices to use as Swift backend (eg. {sdb: {}})'
|
|
type: json
|
|
MonitoringSubscriptionSwiftStorage:
|
|
default: 'overcloud-swift-storage'
|
|
type: string
|
|
SwiftAccountWorkers:
|
|
default: auto
|
|
description: Number of workers for Swift account service.
|
|
type: string
|
|
SwiftContainerWorkers:
|
|
default: auto
|
|
description: Number of workers for Swift account service.
|
|
type: string
|
|
SwiftObjectWorkers:
|
|
default: auto
|
|
description: Number of workers for Swift account service.
|
|
type: string
|
|
SwiftUseLocalDir:
|
|
default: true
|
|
description: 'Use a local directory for Swift storage services when building rings'
|
|
type: boolean
|
|
|
|
# DEPRECATED options for compatibility with overcloud.yaml
|
|
# This should be removed and manipulation of the ControllerServices list
|
|
# used instead, but we need client support for that first
|
|
ControllerEnableSwiftStorage:
|
|
default: true
|
|
description: Whether to enable Swift Storage on the Controller
|
|
type: boolean
|
|
|
|
parameter_groups:
|
|
- label: deprecated
|
|
description: Do not use deprecated params, they will be removed.
|
|
parameters:
|
|
- ControllerEnableSwiftStorage
|
|
|
|
resources:
|
|
SwiftBase:
|
|
type: ./swift-base.yaml
|
|
properties:
|
|
ServiceData: {get_param: ServiceData}
|
|
ServiceNetMap: {get_param: ServiceNetMap}
|
|
DefaultPasswords: {get_param: DefaultPasswords}
|
|
EndpointMap: {get_param: EndpointMap}
|
|
RoleName: {get_param: RoleName}
|
|
RoleParameters: {get_param: RoleParameters}
|
|
|
|
conditions:
|
|
swift_mount_check:
|
|
or:
|
|
- equals:
|
|
- get_param: SwiftMountCheck
|
|
- true
|
|
- not:
|
|
equals:
|
|
- get_param: SwiftRawDisks
|
|
- {}
|
|
|
|
outputs:
|
|
role_data:
|
|
description: Role data for the Swift Proxy role.
|
|
value:
|
|
service_name: swift_storage
|
|
monitoring_subscription: {get_param: MonitoringSubscriptionSwiftStorage}
|
|
config_settings:
|
|
map_merge:
|
|
- get_attr: [SwiftBase, role_data, config_settings]
|
|
- swift::storage::all::mount_check: {if: [swift_mount_check, true, false]}
|
|
tripleo::profile::base::swift::storage::enable_swift_storage: {get_param: ControllerEnableSwiftStorage}
|
|
tripleo::profile::base::swift::storage::use_local_dir: {get_param: SwiftUseLocalDir}
|
|
tripleo.swift_storage.firewall_rules:
|
|
'123 swift storage':
|
|
dport:
|
|
- 873
|
|
- 6000
|
|
- 6001
|
|
- 6002
|
|
swift::storage::all::incoming_chmod: 'Du=rwx,g=rx,o=rx,Fu=rw,g=r,o=r'
|
|
swift::storage::all::outgoing_chmod: 'Du=rwx,g=rx,o=rx,Fu=rw,g=r,o=r'
|
|
swift::storage::all::object_pipeline:
|
|
- healthcheck
|
|
- recon
|
|
- object-server
|
|
swift::storage::all::container_pipeline:
|
|
- healthcheck
|
|
- container-server
|
|
swift::storage::all::account_pipeline:
|
|
- healthcheck
|
|
- account-server
|
|
swift::storage::disks::args: {get_param: SwiftRawDisks}
|
|
swift::storage::all::storage_local_net_ip:
|
|
str_replace:
|
|
template:
|
|
"%{hiera('$NETWORK')}"
|
|
params:
|
|
$NETWORK: {get_param: [ServiceNetMap, SwiftStorageNetwork]}
|
|
swift::storage::all::account_server_workers: {get_param: SwiftAccountWorkers}
|
|
swift::storage::all::container_server_workers: {get_param: SwiftContainerWorkers}
|
|
swift::storage::all::object_server_workers: {get_param: SwiftObjectWorkers}
|
|
step_config: |
|
|
include ::tripleo::profile::base::swift::storage
|
|
upgrade_tasks:
|
|
- name: Stop swift storage services
|
|
when: step|int == 1
|
|
service: name={{ item }} state=stopped
|
|
with_items:
|
|
- openstack-swift-account-auditor
|
|
- openstack-swift-account-reaper
|
|
- openstack-swift-account-replicator
|
|
- openstack-swift-account
|
|
- openstack-swift-container-auditor
|
|
- openstack-swift-container-replicator
|
|
- openstack-swift-container-updater
|
|
- openstack-swift-container
|
|
- openstack-swift-object-auditor
|
|
- openstack-swift-object-expirer
|
|
- openstack-swift-object-replicator
|
|
- openstack-swift-object-updater
|
|
- openstack-swift-object
|