diff --git a/ci/environments/scenario001-multinode-containers.yaml b/ci/environments/scenario001-multinode-containers.yaml index d06f04f0c0..c8426fd1e8 100644 --- a/ci/environments/scenario001-multinode-containers.yaml +++ b/ci/environments/scenario001-multinode-containers.yaml @@ -16,8 +16,8 @@ resource_registry: OS::TripleO::Services::Clustercheck: ../../docker/services/pacemaker/clustercheck.yaml OS::TripleO::Services::Redis: ../../docker/services/pacemaker/database/redis.yaml OS::TripleO::Services::MySQL: ../../docker/services/pacemaker/database/mysql.yaml - OS::TripleO::Services::CinderBackup: ../../docker/services/pacemaker/cinder-backup.yaml - OS::TripleO::Services::CinderVolume: ../../docker/services/pacemaker/cinder-volume.yaml + OS::TripleO::Services::CinderBackup: ../../deployment/cinder/cinder-backup-pacemaker-puppet.yaml + OS::TripleO::Services::CinderVolume: ../../deployment/cinder/cinder-volume-pacemaker-puppet.yaml OS::TripleO::Services::Keepalived: OS::Heat::None #Needs to run scenario001 OS::TripleO::Services::Fluentd: ../../docker/services/fluentd.yaml diff --git a/ci/environments/scenario001-standalone.yaml b/ci/environments/scenario001-standalone.yaml index e9eea1e711..a61605b545 100644 --- a/ci/environments/scenario001-standalone.yaml +++ b/ci/environments/scenario001-standalone.yaml @@ -28,8 +28,8 @@ resource_registry: OS::TripleO::Services::Clustercheck: ../../docker/services/pacemaker/clustercheck.yaml OS::TripleO::Services::Redis: ../../docker/services/pacemaker/database/redis.yaml OS::TripleO::Services::MySQL: ../../docker/services/pacemaker/database/mysql.yaml - OS::TripleO::Services::CinderBackup: ../../docker/services/pacemaker/cinder-backup.yaml - OS::TripleO::Services::CinderVolume: ../../docker/services/pacemaker/cinder-volume.yaml + OS::TripleO::Services::CinderBackup: ../../deployment/cinder/cinder-backup-pacemaker-puppet.yaml + OS::TripleO::Services::CinderVolume: ../../deployment/cinder/cinder-volume-pacemaker-puppet.yaml OS::TripleO::Services::Keepalived: OS::Heat::None #Needs to run scenario001 OS::TripleO::Services::Fluentd: ../../docker/services/fluentd.yaml diff --git a/ci/environments/scenario002-multinode-containers.yaml b/ci/environments/scenario002-multinode-containers.yaml index 627fad17d3..2d7cce88af 100644 --- a/ci/environments/scenario002-multinode-containers.yaml +++ b/ci/environments/scenario002-multinode-containers.yaml @@ -13,8 +13,8 @@ resource_registry: OS::TripleO::Services::PacemakerRemote: ../../puppet/services/pacemaker_remote.yaml OS::TripleO::Services::Clustercheck: ../../docker/services/pacemaker/clustercheck.yaml OS::TripleO::Services::MySQL: ../../docker/services/pacemaker/database/mysql.yaml - OS::TripleO::Services::CinderBackup: ../../docker/services/pacemaker/cinder-backup.yaml - OS::TripleO::Services::CinderVolume: ../../docker/services/pacemaker/cinder-volume.yaml + OS::TripleO::Services::CinderBackup: ../../deployment/cinder/cinder-backup-pacemaker-puppet.yaml + OS::TripleO::Services::CinderVolume: ../../deployment/cinder/cinder-volume-pacemaker-puppet.yaml OS::TripleO::Services::BarbicanBackendSimpleCrypto: ../../puppet/services/barbican-backend-simple-crypto.yaml OS::TripleO::Services::Keepalived: OS::Heat::None # Some infra instances don't pass the ping test but are otherwise working. diff --git a/ci/environments/scenario002-standalone.yaml b/ci/environments/scenario002-standalone.yaml index a16841e66b..347ac3661d 100644 --- a/ci/environments/scenario002-standalone.yaml +++ b/ci/environments/scenario002-standalone.yaml @@ -25,8 +25,8 @@ resource_registry: OS::TripleO::Services::PacemakerRemote: ../../puppet/services/pacemaker_remote.yaml OS::TripleO::Services::Clustercheck: ../../docker/services/pacemaker/clustercheck.yaml OS::TripleO::Services::MySQL: ../../docker/services/pacemaker/database/mysql.yaml - OS::TripleO::Services::CinderBackup: ../../docker/services/pacemaker/cinder-backup.yaml - OS::TripleO::Services::CinderVolume: ../../docker/services/pacemaker/cinder-volume.yaml + OS::TripleO::Services::CinderBackup: ../../deployment/cinder/cinder-backup-pacemaker-puppet.yaml + OS::TripleO::Services::CinderVolume: ../../deployment/cinder/cinder-volume-pacemaker-puppet.yaml OS::TripleO::Services::BarbicanBackendSimpleCrypto: ../../puppet/services/barbican-backend-simple-crypto.yaml # Some infra instances don't pass the ping test but are otherwise working. # Since the OVB jobs also test this functionality we can shut it off here. diff --git a/ci/environments/scenario012-multinode-containers.yaml b/ci/environments/scenario012-multinode-containers.yaml index 398884ac37..09ebf06d4c 100644 --- a/ci/environments/scenario012-multinode-containers.yaml +++ b/ci/environments/scenario012-multinode-containers.yaml @@ -17,7 +17,7 @@ resource_registry: # Since the OVB jobs also test this functionality we can shut it off here. OS::TripleO::AllNodes::Validation: ../common/all-nodes-validation-disabled.yaml OS::TripleO::NodeExtraConfigPost: ../common/vbmc_setup.yaml - OS::TripleO::Services::CinderVolume: ../../docker/services/pacemaker/cinder-volume.yaml + OS::TripleO::Services::CinderVolume: ../../deployment/cinder/cinder-volume-pacemaker-puppet.yaml OS::TripleO::Services::NeutronCorePlugin: OS::TripleO::Services::NeutronCorePluginML2Ansible parameter_defaults: diff --git a/docker/services/cinder-api.yaml b/deployment/cinder/cinder-api-container-puppet.yaml similarity index 65% rename from docker/services/cinder-api.yaml rename to deployment/cinder/cinder-api-container-puppet.yaml index 5b84aafba9..a5838adc62 100644 --- a/docker/services/cinder-api.yaml +++ b/deployment/cinder/cinder-api-container-puppet.yaml @@ -48,21 +48,56 @@ parameters: default: false description: Remove package if the service is being disabled during upgrade type: boolean + CinderDefaultVolumeType: + default: tripleo + description: The name of Cinder's default volume type. + type: string + CinderEnableDBPurge: + default: true + description: | + Whether to create cron job for purging soft deleted rows in Cinder database. + type: boolean + CinderPassword: + description: The password for the cinder service account, used by cinder-api. + type: string + hidden: true + KeystoneRegion: + type: string + default: 'regionOne' + description: Keystone region for endpoint + MonitoringSubscriptionCinderApi: + default: 'overcloud-cinder-api' + type: string + CinderWorkers: + type: string + description: Set the number of workers for cinder::wsgi::apache + default: '%{::os_workers}' + CinderApiPolicies: + description: | + A hash of policies to configure for Cinder API. + e.g. { cinder-context_is_admin: { key: context_is_admin, value: 'role:admin' } } + default: {} + type: json + NotificationDriver: + type: string + default: 'messagingv2' + description: Driver or drivers to handle sending notifications. conditions: internal_tls_enabled: {equals: [{get_param: EnableInternalTLS}, true]} + cinder_workers_zero: {equals : [{get_param: CinderWorkers}, 0]} resources: ContainersCommon: - type: ./containers-common.yaml + type: ../../docker/services/containers-common.yaml MySQLClient: type: ../../puppet/services/database/mysql-client.yaml CinderBase: - type: ../../puppet/services/cinder-api.yaml + type: ./cinder-base.yaml properties: EndpointMap: {get_param: EndpointMap} ServiceData: {get_param: ServiceData} @@ -71,12 +106,81 @@ resources: RoleName: {get_param: RoleName} RoleParameters: {get_param: RoleParameters} + ApacheServiceBase: + type: ../../puppet/services/apache.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} + EnableInternalTLS: {get_param: EnableInternalTLS} + outputs: role_data: description: Role data for the Cinder API role. value: - service_name: {get_attr: [CinderBase, role_data, service_name]} - config_settings: {get_attr: [CinderBase, role_data, config_settings]} + service_name: cinder_api + monitoring_subscription: {get_param: MonitoringSubscriptionCinderApi} + config_settings: + map_merge: + - get_attr: [CinderBase, role_data, config_settings] + - get_attr: [ApacheServiceBase, role_data, config_settings] + - cinder::keystone::authtoken::www_authenticate_uri: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]} + cinder::keystone::authtoken::auth_uri: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]} + cinder::keystone::authtoken::auth_url: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]} + cinder::keystone::authtoken::password: {get_param: CinderPassword} + cinder::keystone::authtoken::project_name: 'service' + cinder::keystone::authtoken::user_domain_name: 'Default' + cinder::keystone::authtoken::project_domain_name: 'Default' + cinder::policy::policies: {get_param: CinderApiPolicies} + cinder::ceilometer::notification_driver: {get_param: NotificationDriver} + cinder::api::default_volume_type: {get_param: CinderDefaultVolumeType} + cinder::api::enable_proxy_headers_parsing: true + + cinder::api::nova_catalog_info: 'compute:nova:internalURL' + # TODO(emilien) move it to puppet-cinder + cinder::config: + DEFAULT/swift_catalog_info: + value: 'object-store:swift:internalURL' + tripleo::profile::base::cinder::cinder_enable_db_purge: {get_param: CinderEnableDBPurge} + tripleo::cinder_api::firewall_rules: + '119 cinder': + dport: + - 8776 + - 13776 + cinder::api::bind_host: + str_replace: + template: + "%{hiera('fqdn_$NETWORK')}" + params: + $NETWORK: {get_param: [ServiceNetMap, CinderApiNetwork]} + cinder::wsgi::apache::ssl: {get_param: EnableInternalTLS} + cinder::api::service_name: 'httpd' + # NOTE: bind IP is found in hiera replacing the network name with the local node IP + # for the given network; replacement examples (eg. for internal_api): + # internal_api -> IP + # internal_api_uri -> [IP] + # internal_api_subnet - > IP/CIDR + cinder::wsgi::apache::bind_host: + str_replace: + template: + "%{hiera('$NETWORK')}" + params: + $NETWORK: {get_param: [ServiceNetMap, CinderApiNetwork]} + - + cinder::wsgi::apache::servername: + str_replace: + template: + "%{hiera('fqdn_$NETWORK')}" + params: + $NETWORK: {get_param: [ServiceNetMap, CinderApiNetwork]} + - + if: + - cinder_workers_zero + - {} + - cinder::wsgi::apache::workers: {get_param: CinderWorkers} service_config_settings: map_merge: - get_attr: [CinderBase, role_data, service_config_settings] @@ -85,6 +189,27 @@ outputs: - cinder tripleo_fluentd_sources_cinder_api: - {get_param: CinderApiLoggingSource} + keystone: + cinder::keystone::auth::tenant: 'service' + cinder::keystone::auth::public_url: {get_param: [EndpointMap, CinderPublic, uri]} + cinder::keystone::auth::internal_url: {get_param: [EndpointMap, CinderInternal, uri]} + cinder::keystone::auth::admin_url: {get_param: [EndpointMap, CinderAdmin, uri]} + cinder::keystone::auth::public_url_v2: {get_param: [EndpointMap, CinderV2Public, uri]} + cinder::keystone::auth::internal_url_v2: {get_param: [EndpointMap, CinderV2Internal, uri]} + cinder::keystone::auth::admin_url_v2: {get_param: [EndpointMap, CinderV2Admin, uri]} + cinder::keystone::auth::public_url_v3: {get_param: [EndpointMap, CinderV3Public, uri]} + cinder::keystone::auth::internal_url_v3: {get_param: [EndpointMap, CinderV3Internal, uri]} + cinder::keystone::auth::admin_url_v3: {get_param: [EndpointMap, CinderV3Admin, uri]} + cinder::keystone::auth::password: {get_param: CinderPassword} + cinder::keystone::auth::region: {get_param: KeystoneRegion} + mysql: + cinder::db::mysql::password: {get_param: CinderPassword} + cinder::db::mysql::user: cinder + cinder::db::mysql::host: {get_param: [EndpointMap, MysqlInternal, host_nobrackets]} + cinder::db::mysql::dbname: cinder + cinder::db::mysql::allowed_hosts: + - '%' + - "%{hiera('mysql_bind_host')}" # BEGIN DOCKER SETTINGS puppet_config: config_volume: cinder @@ -92,7 +217,7 @@ outputs: step_config: list_join: - "\n" - - - {get_attr: [CinderBase, role_data, step_config]} + - - "include ::tripleo::profile::base::cinder::api" - {get_attr: [MySQLClient, role_data, step_config]} config_image: {get_param: DockerCinderConfigImage} kolla_config: @@ -207,7 +332,7 @@ outputs: - /var/lib/config-data/cinder/etc/cinder/:/etc/cinder/:ro metadata_settings: - get_attr: [CinderBase, role_data, metadata_settings] + get_attr: [ApacheServiceBase, role_data, metadata_settings] host_prep_tasks: - name: create persistent directories file: diff --git a/puppet/services/cinder-backend-dellemc-unity.yaml b/deployment/cinder/cinder-backend-dellemc-unity-puppet.yaml similarity index 100% rename from puppet/services/cinder-backend-dellemc-unity.yaml rename to deployment/cinder/cinder-backend-dellemc-unity-puppet.yaml diff --git a/puppet/services/cinder-backend-dellemc-vmax-iscsi.yaml b/deployment/cinder/cinder-backend-dellemc-vmax-iscsi-puppet.yaml similarity index 100% rename from puppet/services/cinder-backend-dellemc-vmax-iscsi.yaml rename to deployment/cinder/cinder-backend-dellemc-vmax-iscsi-puppet.yaml diff --git a/puppet/services/cinder-backend-dellemc-vnx.yaml b/deployment/cinder/cinder-backend-dellemc-vnx-puppet.yaml similarity index 100% rename from puppet/services/cinder-backend-dellemc-vnx.yaml rename to deployment/cinder/cinder-backend-dellemc-vnx-puppet.yaml diff --git a/puppet/services/cinder-backend-dellemc-xtremio-iscsi.yaml b/deployment/cinder/cinder-backend-dellemc-xtremio-iscsi-puppet.yaml similarity index 100% rename from puppet/services/cinder-backend-dellemc-xtremio-iscsi.yaml rename to deployment/cinder/cinder-backend-dellemc-xtremio-iscsi-puppet.yaml diff --git a/puppet/services/cinder-backend-dellps.yaml b/deployment/cinder/cinder-backend-dellps-puppet.yaml similarity index 100% rename from puppet/services/cinder-backend-dellps.yaml rename to deployment/cinder/cinder-backend-dellps-puppet.yaml diff --git a/puppet/services/cinder-backend-dellsc.yaml b/deployment/cinder/cinder-backend-dellsc-puppet.yaml similarity index 100% rename from puppet/services/cinder-backend-dellsc.yaml rename to deployment/cinder/cinder-backend-dellsc-puppet.yaml diff --git a/puppet/services/cinder-backend-netapp.yaml b/deployment/cinder/cinder-backend-netapp-puppet.yaml similarity index 100% rename from puppet/services/cinder-backend-netapp.yaml rename to deployment/cinder/cinder-backend-netapp-puppet.yaml diff --git a/puppet/services/cinder-backend-nvmeof.yaml b/deployment/cinder/cinder-backend-nvmeof-puppet.yaml similarity index 100% rename from puppet/services/cinder-backend-nvmeof.yaml rename to deployment/cinder/cinder-backend-nvmeof-puppet.yaml diff --git a/puppet/services/cinder-backend-pure.yaml b/deployment/cinder/cinder-backend-pure-puppet.yaml similarity index 100% rename from puppet/services/cinder-backend-pure.yaml rename to deployment/cinder/cinder-backend-pure-puppet.yaml diff --git a/puppet/services/cinder-backend-scaleio.yaml b/deployment/cinder/cinder-backend-scaleio-puppet.yaml similarity index 100% rename from puppet/services/cinder-backend-scaleio.yaml rename to deployment/cinder/cinder-backend-scaleio-puppet.yaml diff --git a/puppet/services/cinder-backend-veritas-hyperscale.yaml b/deployment/cinder/cinder-backend-veritas-hyperscale-puppet.yaml similarity index 100% rename from puppet/services/cinder-backend-veritas-hyperscale.yaml rename to deployment/cinder/cinder-backend-veritas-hyperscale-puppet.yaml diff --git a/docker/services/cinder-backup.yaml b/deployment/cinder/cinder-backup-container-puppet.yaml similarity index 74% rename from docker/services/cinder-backup.yaml rename to deployment/cinder/cinder-backup-container-puppet.yaml index 130ee51a44..a00d3b366c 100644 --- a/docker/services/cinder-backup.yaml +++ b/deployment/cinder/cinder-backup-container-puppet.yaml @@ -57,17 +57,50 @@ parameters: default: tag: openstack.cinder.backup path: /var/log/containers/cinder/cinder-backup.log + CinderBackupBackend: + default: swift + description: The short name of the Cinder Backup backend to use. + type: string + constraints: + - allowed_values: ['swift', 'ceph', 'nfs'] + CinderBackupRbdPoolName: + default: backups + type: string + CephClusterName: + type: string + default: ceph + description: The Ceph cluster name. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + description: > + The Ceph cluster name must be at least 1 character and contain only + letters and numbers. + CephClientUserName: + default: openstack + type: string + CinderBackupNfsShare: + default: '' + description: NFS share to be mounted + type: string + CinderBackupNfsMountOptions: + default: '' + description: Mount options passed to the NFS client. See NFS man + page for details. + type: string + MonitoringSubscriptionCinderBackup: + default: 'overcloud-cinder-backup' + type: string resources: ContainersCommon: - type: ./containers-common.yaml + type: ../../docker/services/containers-common.yaml MySQLClient: type: ../../puppet/services/database/mysql-client.yaml CinderBase: - type: ../../puppet/services/cinder-backup.yaml + type: ./cinder-base.yaml properties: EndpointMap: {get_param: EndpointMap} ServiceData: {get_param: ServiceData} @@ -77,14 +110,28 @@ resources: RoleParameters: {get_param: RoleParameters} CinderCommon: - type: ./cinder-common.yaml + type: ./cinder-common-container-puppet.yaml outputs: role_data: description: Role data for the Cinder Backup role. value: - service_name: {get_attr: [CinderBase, role_data, service_name]} - config_settings: {get_attr: [CinderBase, role_data, config_settings]} + service_name: cinder_backup + monitoring_subscription: {get_param: MonitoringSubscriptionCinderBackup} + config_settings: + map_merge: + - get_attr: [CinderBase, role_data, config_settings] + - cinder::backup::ceph::backup_ceph_user: {get_param: CephClientUserName} + cinder::backup::ceph::backup_ceph_pool: {get_param: CinderBackupRbdPoolName} + cinder::backup::ceph::backup_ceph_conf: + list_join: + - '' + - - '/etc/ceph/' + - {get_param: CephClusterName} + - '.conf' + cinder::backup::swift::backup_swift_container: volumebackups + cinder::backup::nfs::backup_share: {get_param: CinderBackupNfsShare} + cinder::backup::nfs::backup_mount_options: {get_param: CinderBackupNfsMountOptions} service_config_settings: map_merge: - get_attr: [CinderBase, role_data, service_config_settings] @@ -98,6 +145,10 @@ outputs: config_volume: cinder puppet_tags: cinder_config,file,concat,file_line step_config: + str_replace: + template: "include ::tripleo::profile::base::cinder::backup::DRIVER" + params: + DRIVER: {get_param: CinderBackupBackend} list_join: - "\n" - - {get_attr: [CinderBase, role_data, step_config]} diff --git a/docker/services/pacemaker/cinder-backup.yaml b/deployment/cinder/cinder-backup-pacemaker-puppet.yaml similarity index 97% rename from docker/services/pacemaker/cinder-backup.yaml rename to deployment/cinder/cinder-backup-pacemaker-puppet.yaml index 9975620987..055249dadf 100644 --- a/docker/services/pacemaker/cinder-backup.yaml +++ b/deployment/cinder/cinder-backup-pacemaker-puppet.yaml @@ -81,13 +81,13 @@ conditions: resources: ContainersCommon: - type: ../containers-common.yaml + type: ../../docker/services/containers-common.yaml MySQLClient: - type: ../../../puppet/services/database/mysql-client.yaml + type: ../../puppet/services/database/mysql-client.yaml CinderBackupBase: - type: ../../../puppet/services/cinder-backup.yaml + type: ./cinder-backup-container-puppet.yaml properties: EndpointMap: {get_param: EndpointMap} ServiceData: {get_param: ServiceData} @@ -100,13 +100,14 @@ resources: CephClientUserName: {get_param: CephClientUserName} CinderCommon: - type: ../cinder-common.yaml + type: ./cinder-common-container-puppet.yaml outputs: role_data: description: Role data for the Cinder Backup role. value: - service_name: {get_attr: [CinderBackupBase, role_data, service_name]} + service_name: cinder_backup + monitoring_subscription: {get_attr: [CinderBackupBase, role_data, monitoring_subscription]} config_settings: map_merge: - get_attr: [CinderBackupBase, role_data, config_settings] @@ -139,6 +140,7 @@ outputs: - "\n" - - {get_attr: [CinderBackupBase, role_data, step_config]} - {get_attr: [MySQLClient, role_data, step_config]} + - "include ::tripleo::profile::pacemaker::cinder::backup" config_image: {get_param: DockerCinderConfigImage} kolla_config: /var/lib/kolla/config_files/cinder_backup.json: diff --git a/puppet/services/cinder-base.yaml b/deployment/cinder/cinder-base.yaml similarity index 100% rename from puppet/services/cinder-base.yaml rename to deployment/cinder/cinder-base.yaml diff --git a/docker/services/cinder-common.yaml b/deployment/cinder/cinder-common-container-puppet.yaml similarity index 99% rename from docker/services/cinder-common.yaml rename to deployment/cinder/cinder-common-container-puppet.yaml index e3bcf31f99..487c2a6393 100644 --- a/docker/services/cinder-common.yaml +++ b/deployment/cinder/cinder-common-container-puppet.yaml @@ -52,7 +52,7 @@ parameters: resources: ContainersCommon: - type: ./containers-common.yaml + type: ../../docker/services/containers-common.yaml outputs: cinder_common_host_prep_tasks: diff --git a/puppet/services/cinder-hpelefthand-iscsi.yaml b/deployment/cinder/cinder-hpelefthand-iscsi-puppet.yaml similarity index 100% rename from puppet/services/cinder-hpelefthand-iscsi.yaml rename to deployment/cinder/cinder-hpelefthand-iscsi-puppet.yaml diff --git a/docker/services/cinder-scheduler.yaml b/deployment/cinder/cinder-scheduler-container-puppet.yaml similarity index 92% rename from docker/services/cinder-scheduler.yaml rename to deployment/cinder/cinder-scheduler-container-puppet.yaml index 37c89714a4..64717c7d48 100644 --- a/docker/services/cinder-scheduler.yaml +++ b/deployment/cinder/cinder-scheduler-container-puppet.yaml @@ -45,17 +45,20 @@ parameters: default: false description: Remove package if the service is being disabled during upgrade type: boolean + MonitoringSubscriptionCinderScheduler: + default: 'overcloud-cinder-scheduler' + type: string resources: ContainersCommon: - type: ./containers-common.yaml + type: ../../docker/services/containers-common.yaml MySQLClient: type: ../../puppet/services/database/mysql-client.yaml CinderBase: - type: ../../puppet/services/cinder-scheduler.yaml + type: ./cinder-base.yaml properties: EndpointMap: {get_param: EndpointMap} ServiceData: {get_param: ServiceData} @@ -68,8 +71,12 @@ outputs: role_data: description: Role data for the Cinder Scheduler role. value: - service_name: {get_attr: [CinderBase, role_data, service_name]} - config_settings: {get_attr: [CinderBase, role_data, config_settings]} + service_name: cinder_scheduler + monitoring_subscription: {get_param: MonitoringSubscriptionCinderScheduler} + config_settings: + map_merge: + - get_attr: [CinderBase, role_data, config_settings] + - cinder::scheduler::scheduler_driver: cinder.scheduler.filter_scheduler.FilterScheduler service_config_settings: map_merge: - get_attr: [CinderBase, role_data, service_config_settings] @@ -85,6 +92,7 @@ outputs: step_config: list_join: - "\n" + - - "include ::tripleo::profile::base::cinder::scheduler" - - {get_attr: [CinderBase, role_data, step_config]} - {get_attr: [MySQLClient, role_data, step_config]} config_image: {get_param: DockerCinderConfigImage} diff --git a/puppet/services/cinder-volume.yaml b/deployment/cinder/cinder-volume-container-puppet.yaml similarity index 61% rename from puppet/services/cinder-volume.yaml rename to deployment/cinder/cinder-volume-container-puppet.yaml index 35af0486fb..da67dd3d78 100644 --- a/puppet/services/cinder-volume.yaml +++ b/deployment/cinder/cinder-volume-container-puppet.yaml @@ -1,9 +1,66 @@ heat_template_version: rocky description: > - OpenStack Cinder Volume service configured with Puppet + OpenStack containerized Cinder Volume service parameters: + DockerCinderVolumeImage: + description: image + type: string + DockerCinderConfigImage: + description: The container image to use for the cinder config_volume + type: string + DockerCinderVolumeUlimit: + default: ['nofile=131072'] + description: ulimit for Cinder Volume Container + type: comma_delimited_list + CinderVolumeLoggingSource: + type: json + default: + tag: openstack.cinder.volume + path: /var/log/containers/cinder/cinder-volume.log + EndpointMap: + default: {} + description: Mapping of service endpoint -> protocol. Typically set + via parameter_defaults in the resource registry. + type: json + 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 + UpgradeRemoveUnusedPackages: + default: false + description: Remove package if the service is being disabled during upgrade + type: boolean + CephClientUserName: + default: openstack + type: string + CephClusterName: + type: string + default: ceph + description: The Ceph cluster name. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + description: > + The Ceph cluster name must be at least 1 character and contain only + letters and numbers. CinderEnableNfsBackend: default: false description: Whether to enable or not the NFS backend for Cinder @@ -92,65 +149,31 @@ parameters: CephClusterFSID: type: string description: The Ceph cluster FSID. Must be a UUID. - CephClusterName: - type: string - default: ceph - description: The Ceph cluster name. - constraints: - - allowed_pattern: "[a-zA-Z0-9]+" - description: > - The Ceph cluster name must be at least 1 character and contain only - letters and numbers. - CephClientUserName: - default: openstack - type: string - 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 MonitoringSubscriptionCinderVolume: default: 'overcloud-cinder-volume' type: string - CinderVolumeLoggingSource: - type: json - default: - tag: openstack.cinder.volume - path: /var/log/cinder/cinder-volume.log resources: + ContainersCommon: + type: ../../docker/services/containers-common.yaml + + MySQLClient: + type: ../../puppet/services/database/mysql-client.yaml + CinderBase: type: ./cinder-base.yaml properties: + EndpointMap: {get_param: EndpointMap} ServiceData: {get_param: ServiceData} ServiceNetMap: {get_param: ServiceNetMap} DefaultPasswords: {get_param: DefaultPasswords} - EndpointMap: {get_param: EndpointMap} RoleName: {get_param: RoleName} RoleParameters: {get_param: RoleParameters} + CinderCommon: + type: ./cinder-common-container-puppet.yaml + outputs: role_data: description: Role data for the Cinder Volume role. @@ -160,6 +183,7 @@ outputs: config_settings: map_merge: - get_attr: [CinderBase, role_data, config_settings] + - tripleo::profile::base::lvm::enable_udev: false - tripleo::profile::base::cinder::volume::cinder_enable_iscsi_backend: {get_param: CinderEnableIscsiBackend} tripleo::profile::base::cinder::volume::cinder_enable_nfs_backend: {get_param: CinderEnableNfsBackend} tripleo::profile::base::cinder::volume::cinder_enable_rbd_backend: {get_param: CinderEnableRbdBackend} @@ -211,11 +235,114 @@ outputs: - {} - tripleo::profile::base::cinder::volume::rbd::backend_availability_zone: {get_param: CinderRbdAvailabilityZone} service_config_settings: - fluentd: - tripleo_fluentd_groups_cinder_volume: - - cinder - tripleo_fluentd_sources_cinder_volume: - - {get_param: CinderVolumeLoggingSource} - step_config: | - include ::tripleo::profile::base::cinder::volume - upgrade_tasks: [] + map_merge: + - get_attr: [CinderBase, role_data, service_config_settings] + - fluentd: + tripleo_fluentd_groups_cinder_volume: + - cinder + tripleo_fluentd_sources_cinder_volume: + - {get_param: CinderVolumeLoggingSource} + # BEGIN DOCKER SETTINGS + puppet_config: + config_volume: cinder + puppet_tags: cinder_config,file,concat,file_line + step_config: + list_join: + - "\n" + - - "include ::tripleo::profile::base::lvm" + - "include ::tripleo::profile::base::cinder::volume" + - get_attr: [MySQLClient, role_data, step_config] + config_image: {get_param: DockerCinderConfigImage} + kolla_config: + /var/lib/kolla/config_files/cinder_volume.json: + command: /usr/bin/cinder-volume --config-file /usr/share/cinder/cinder-dist.conf --config-file /etc/cinder/cinder.conf + config_files: + - source: "/var/lib/kolla/config_files/src/*" + dest: "/" + merge: true + preserve_properties: true + - source: "/var/lib/kolla/config_files/src-ceph/" + dest: "/etc/ceph/" + merge: true + preserve_properties: true + - source: "/var/lib/kolla/config_files/src-iscsid/*" + dest: "/etc/iscsi/" + merge: true + preserve_properties: true + permissions: + - path: /var/log/cinder + owner: cinder:cinder + recurse: true + - path: + str_replace: + template: /etc/ceph/CLUSTER.client.USER.keyring + params: + CLUSTER: {get_param: CephClusterName} + USER: {get_param: CephClientUserName} + owner: cinder:cinder + perm: '0600' + docker_config: + step_3: + cinder_volume_init_logs: + start_order: 0 + image: &cinder_volume_image {get_param: DockerCinderVolumeImage} + privileged: false + user: root + volumes: + - /var/log/containers/cinder:/var/log/cinder:z + command: ['/bin/bash', '-c', 'chown -R cinder:cinder /var/log/cinder'] + step_4: + cinder_volume: + image: *cinder_volume_image + ulimit: {get_param: DockerCinderVolumeUlimit} + ipc: host + net: host + privileged: true + restart: always + healthcheck: + test: + list_join: + - ' ' + - - '/openstack/healthcheck' + - yaql: + expression: str($.data.port) + data: + port: {get_attr: [CinderBase, role_data, config_settings, 'cinder::rabbit_port']} + volumes: {get_attr: [CinderCommon, cinder_volume_volumes]} + environment: {get_attr: [CinderCommon, cinder_volume_environment]} + host_prep_tasks: {get_attr: [CinderCommon, cinder_volume_host_prep_tasks]} + upgrade_tasks: + - when: step|int == 3 + block: + - name: Set fact for removal of openstack-cinder package + set_fact: + remove_cinder_package: {get_param: UpgradeRemoveUnusedPackages} + - name: Remove openstack-cinder package if operator requests it + package: name=openstack-cinder state=removed + ignore_errors: True + when: remove_cinder_package|bool + post_upgrade_tasks: + - when: step|int == 1 + import_role: + name: tripleo-docker-rm + vars: + containers_to_rm: + - cinder_volume + fast_forward_upgrade_tasks: + - when: + - step|int == 0 + - release == 'ocata' + block: + - name: Check if cinder_volume is deployed + command: systemctl is-enabled --quiet openstack-cinder-volume + ignore_errors: True + register: cinder_volume_enabled_result + - name: Set fact cinder_volume_enabled + set_fact: + cinder_volume_enabled: "{{ cinder_volume_enabled_result.rc == 0 }}" + - name: Stop openstack-cinder-volume + service: name=openstack-cinder-volume state=stopped enabled=no + when: + - step|int == 1 + - release == 'ocata' + - cinder_volume_enabled|bool diff --git a/docker/services/pacemaker/cinder-volume.yaml b/deployment/cinder/cinder-volume-pacemaker-puppet.yaml similarity index 95% rename from docker/services/pacemaker/cinder-volume.yaml rename to deployment/cinder/cinder-volume-pacemaker-puppet.yaml index 3c45c651ad..cec84ead25 100644 --- a/docker/services/pacemaker/cinder-volume.yaml +++ b/deployment/cinder/cinder-volume-pacemaker-puppet.yaml @@ -69,13 +69,13 @@ conditions: resources: ContainersCommon: - type: ../containers-common.yaml + type: ../../docker/services/containers-common.yaml MySQLClient: - type: ../../../puppet/services/database/mysql-client.yaml + type: ../../puppet/services/database/mysql-client.yaml CinderBase: - type: ../../../puppet/services/cinder-volume.yaml + type: ./cinder-volume-container-puppet.yaml properties: EndpointMap: {get_param: EndpointMap} ServiceData: {get_param: ServiceData} @@ -85,13 +85,14 @@ resources: RoleParameters: {get_param: RoleParameters} CinderCommon: - type: ../cinder-common.yaml + type: ./cinder-common-container-puppet.yaml outputs: role_data: description: Role data for the Cinder Volume role. value: - service_name: {get_attr: [CinderBase, role_data, service_name]} + service_name: cinder_volume + monitoring_subscription: {get_attr: [CinderBase, role_data, monitoring_subscription]} config_settings: map_merge: - get_attr: [CinderBase, role_data, config_settings] @@ -125,7 +126,7 @@ outputs: list_join: - "\n" - - "include ::tripleo::profile::base::lvm" - - get_attr: [CinderBase, role_data, step_config] + - - "include ::tripleo::profile::pacemaker::cinder::volume" - get_attr: [MySQLClient, role_data, step_config] config_image: {get_param: DockerCinderConfigImage} kolla_config: @@ -293,6 +294,12 @@ outputs: - name: set is_cinder_volume_bootstrap_node fact tags: common set_fact: is_cinder_volume_bootstrap_node={{cinder_volume_short_bootstrap_node_name|lower == ansible_hostname|lower}} + - name: Stop cinder_volume service (pacemaker) + when: step|int == 1 + pacemaker_resource: + resource: openstack-cinder-volume + state: disable + wait_for_resource: true - name: Cinder-Volume baremetal to container upgrade tasks when: - step|int == 1 @@ -356,6 +363,12 @@ outputs: - step|int == 3 - cinder_volume_containerized|bool block: *cinder_volume_fetch_retag_container_tasks + post_upgrade_tasks: + - name: Start cinder_volume service (pacemaker) + when: step|int == 1 + pacemaker_resource: + resource: openstack-cinder-volume + state: enable fast_forward_upgrade_tasks: - when: - step|int == 0 diff --git a/docker/services/cinder-volume.yaml b/docker/services/cinder-volume.yaml deleted file mode 100644 index 653a2f5f5e..0000000000 --- a/docker/services/cinder-volume.yaml +++ /dev/null @@ -1,213 +0,0 @@ -heat_template_version: rocky - -description: > - OpenStack containerized Cinder Volume service - -parameters: - DockerCinderVolumeImage: - description: image - type: string - DockerCinderConfigImage: - description: The container image to use for the cinder config_volume - type: string - DockerCinderVolumeUlimit: - default: ['nofile=131072'] - description: ulimit for Cinder Volume Container - type: comma_delimited_list - CinderVolumeLoggingSource: - type: json - default: - tag: openstack.cinder.volume - path: /var/log/containers/cinder/cinder-volume.log - EndpointMap: - default: {} - description: Mapping of service endpoint -> protocol. Typically set - via parameter_defaults in the resource registry. - type: json - 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 - UpgradeRemoveUnusedPackages: - default: false - description: Remove package if the service is being disabled during upgrade - type: boolean - CephClientUserName: - default: openstack - type: string - CephClusterName: - type: string - default: ceph - description: The Ceph cluster name. - constraints: - - allowed_pattern: "[a-zA-Z0-9]+" - description: > - The Ceph cluster name must be at least 1 character and contain only - letters and numbers. - -resources: - - ContainersCommon: - type: ./containers-common.yaml - - MySQLClient: - type: ../../puppet/services/database/mysql-client.yaml - - CinderBase: - type: ../../puppet/services/cinder-volume.yaml - properties: - EndpointMap: {get_param: EndpointMap} - ServiceData: {get_param: ServiceData} - ServiceNetMap: {get_param: ServiceNetMap} - DefaultPasswords: {get_param: DefaultPasswords} - RoleName: {get_param: RoleName} - RoleParameters: {get_param: RoleParameters} - - CinderCommon: - type: ./cinder-common.yaml - -outputs: - role_data: - description: Role data for the Cinder Volume role. - value: - service_name: {get_attr: [CinderBase, role_data, service_name]} - config_settings: - map_merge: - - get_attr: [CinderBase, role_data, config_settings] - - tripleo::profile::base::lvm::enable_udev: false - service_config_settings: - map_merge: - - get_attr: [CinderBase, role_data, service_config_settings] - - fluentd: - tripleo_fluentd_groups_cinder_volume: - - cinder - tripleo_fluentd_sources_cinder_volume: - - {get_param: CinderVolumeLoggingSource} - # BEGIN DOCKER SETTINGS - puppet_config: - config_volume: cinder - puppet_tags: cinder_config,file,concat,file_line - step_config: - list_join: - - "\n" - - - "include ::tripleo::profile::base::lvm" - - get_attr: [CinderBase, role_data, step_config] - - get_attr: [MySQLClient, role_data, step_config] - config_image: {get_param: DockerCinderConfigImage} - kolla_config: - /var/lib/kolla/config_files/cinder_volume.json: - command: /usr/bin/cinder-volume --config-file /usr/share/cinder/cinder-dist.conf --config-file /etc/cinder/cinder.conf - config_files: - - source: "/var/lib/kolla/config_files/src/*" - dest: "/" - merge: true - preserve_properties: true - - source: "/var/lib/kolla/config_files/src-ceph/" - dest: "/etc/ceph/" - merge: true - preserve_properties: true - - source: "/var/lib/kolla/config_files/src-iscsid/*" - dest: "/etc/iscsi/" - merge: true - preserve_properties: true - permissions: - - path: /var/log/cinder - owner: cinder:cinder - recurse: true - - path: - str_replace: - template: /etc/ceph/CLUSTER.client.USER.keyring - params: - CLUSTER: {get_param: CephClusterName} - USER: {get_param: CephClientUserName} - owner: cinder:cinder - perm: '0600' - docker_config: - step_3: - cinder_volume_init_logs: - start_order: 0 - image: &cinder_volume_image {get_param: DockerCinderVolumeImage} - privileged: false - user: root - volumes: - - /var/log/containers/cinder:/var/log/cinder:z - command: ['/bin/bash', '-c', 'chown -R cinder:cinder /var/log/cinder'] - step_4: - cinder_volume: - image: *cinder_volume_image - ulimit: {get_param: DockerCinderVolumeUlimit} - ipc: host - net: host - privileged: true - restart: always - healthcheck: - test: - list_join: - - ' ' - - - '/openstack/healthcheck' - - yaql: - expression: str($.data.port) - data: - port: {get_attr: [CinderBase, role_data, config_settings, 'cinder::rabbit_port']} - volumes: {get_attr: [CinderCommon, cinder_volume_volumes]} - environment: {get_attr: [CinderCommon, cinder_volume_environment]} - host_prep_tasks: - list_concat: - - {get_attr: [CinderCommon, cinder_volume_host_prep_tasks]} - - - name: enable virt_sandbox_use_netlink for healthcheck - seboolean: - name: virt_sandbox_use_netlink - persistent: yes - state: yes - upgrade_tasks: - - when: step|int == 3 - block: - - name: Set fact for removal of openstack-cinder package - set_fact: - remove_cinder_package: {get_param: UpgradeRemoveUnusedPackages} - - name: Remove openstack-cinder package if operator requests it - package: name=openstack-cinder state=removed - ignore_errors: True - when: remove_cinder_package|bool - post_upgrade_tasks: - - when: step|int == 1 - import_role: - name: tripleo-docker-rm - vars: - containers_to_rm: - - cinder_volume - fast_forward_upgrade_tasks: - - when: - - step|int == 0 - - release == 'ocata' - block: - - name: Check if cinder_volume is deployed - command: systemctl is-enabled --quiet openstack-cinder-volume - ignore_errors: True - register: cinder_volume_enabled_result - - name: Set fact cinder_volume_enabled - set_fact: - cinder_volume_enabled: "{{ cinder_volume_enabled_result.rc == 0 }}" - - name: Stop openstack-cinder-volume - service: name=openstack-cinder-volume state=stopped enabled=no - when: - - step|int == 1 - - release == 'ocata' - - cinder_volume_enabled|bool diff --git a/environments/baremetal-services.yaml b/environments/baremetal-services.yaml index a59519f7e6..a5eb6ab40a 100644 --- a/environments/baremetal-services.yaml +++ b/environments/baremetal-services.yaml @@ -6,13 +6,13 @@ resource_registry: OS::TripleO::Services::AodhEvaluator: ../deployment/aodh/aodh-evaluator-container-puppet.yaml OS::TripleO::Services::AodhNotifier: ../deployment/aodh/aodh-notifier-container-puppet.yaml OS::TripleO::Services::AodhListener: ../deployment/aodh/aodh-listener-container-puppet.yaml - OS::TripleO::Services::BlockStorageCinderVolume: ../puppet/services/cinder-volume.yaml + OS::TripleO::Services::BlockStorageCinderVolume: ../deployment/cinder/cinder-volume-container-puppet.yaml OS::TripleO::Services::CeilometerAgentCentral: ../puppet/services/ceilometer-agent-central.yaml OS::TripleO::Services::CeilometerAgentIpmi: ../puppet/services/ceilometer-agent-ipmi.yaml OS::TripleO::Services::CeilometerAgentNotification: ../puppet/services/ceilometer-agent-notification.yaml - OS::TripleO::Services::CinderApi: ../puppet/services/cinder-api.yaml - OS::TripleO::Services::CinderScheduler: ../puppet/services/cinder-scheduler.yaml - OS::TripleO::Services::CinderVolume: ../puppet/services/cinder-volume.yaml + OS::TripleO::Services::CinderApi: ../deployment/cinder/cinder-api-container-puppet.yaml + OS::TripleO::Services::CinderScheduler: ../deployment/cinder/cinder-scheduler-container-puppet.yaml + OS::TripleO::Services::CinderVolume: ../deployment/cinder/cinder-volume-container-puppet.yaml OS::TripleO::Services::ComputeCeilometerAgent: ../puppet/services/ceilometer-agent-compute.yaml OS::TripleO::Services::ComputeNeutronOvsAgent: ../puppet/services/neutron-ovs-agent.yaml OS::TripleO::Services::ContainersLogrotateCrond: OS::Heat::None diff --git a/environments/cinder-backup.yaml b/environments/cinder-backup.yaml index 60845e6a5f..d8ae01748b 100644 --- a/environments/cinder-backup.yaml +++ b/environments/cinder-backup.yaml @@ -1,4 +1,4 @@ resource_registry: - OS::TripleO::Services::CinderBackup: ../docker/services/pacemaker/cinder-backup.yaml + OS::TripleO::Services::CinderBackup: ../deployment/cinder/cinder-backup-pacemaker-puppet.yaml # For non-pcmk managed implementation - # OS::TripleO::Services::CinderBackup: ../docker/services/cinder-backup.yaml + # OS::TripleO::Services::CinderBackup: ../deployment/cinder/cinder-backup-container-puppet.yaml diff --git a/environments/cinder-dellemc-unity-config.yaml b/environments/cinder-dellemc-unity-config.yaml index c67c91cba2..6cec6d7be9 100644 --- a/environments/cinder-dellemc-unity-config.yaml +++ b/environments/cinder-dellemc-unity-config.yaml @@ -1,7 +1,7 @@ # A Heat environment file which can be used to enable a # Cinder Dell EMC Unity backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderBackendDellEMCUnity: ../puppet/services/cinder-backend-dellemc-unity.yaml + OS::TripleO::Services::CinderBackendDellEMCUnity: ../deployment/cinder/cinder-backend-dellemc-unity-puppet.yaml parameter_defaults: CinderEnableDellEMCUnityBackend: true diff --git a/environments/cinder-dellemc-vmax-iscsi-config.yaml b/environments/cinder-dellemc-vmax-iscsi-config.yaml index 3832dada75..624671c0a5 100644 --- a/environments/cinder-dellemc-vmax-iscsi-config.yaml +++ b/environments/cinder-dellemc-vmax-iscsi-config.yaml @@ -1,7 +1,7 @@ # A Heat environment file which can be used to enable a # Cinder Dell EMC VMAX backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderBackendDellEMCVMAXISCSI: ../puppet/services/cinder-backend-dellemc-vmax-iscsi.yaml + OS::TripleO::Services::CinderBackendDellEMCVMAXISCSI: ../deployment/cinder/cinder-backend-dellemc-vmax-iscsi-puppet.yaml parameter_defaults: CinderEnableDellEMCVMAXISCSIBackend: true diff --git a/environments/cinder-dellemc-vnx-config.yaml b/environments/cinder-dellemc-vnx-config.yaml index 1f975fa33f..fa3e36afc5 100644 --- a/environments/cinder-dellemc-vnx-config.yaml +++ b/environments/cinder-dellemc-vnx-config.yaml @@ -1,7 +1,7 @@ # A Heat environment file which can be used to enable a # Cinder Dell EMC VNX backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderBackendDellEMCVNX: ../puppet/services/cinder-backend-dellemc-vnx.yaml + OS::TripleO::Services::CinderBackendDellEMCVNX: ../deployment/cinder/cinder-backend-dellemc-vnx-puppet.yaml parameter_defaults: CinderEnableDellEMCVNXBackend: true diff --git a/environments/cinder-dellemc-xtremio-iscsi-config.yaml b/environments/cinder-dellemc-xtremio-iscsi-config.yaml index 608a808e37..62e50e9731 100644 --- a/environments/cinder-dellemc-xtremio-iscsi-config.yaml +++ b/environments/cinder-dellemc-xtremio-iscsi-config.yaml @@ -1,7 +1,7 @@ # A Heat environment file which can be used to enable a # Cinder Dell EMC XTREMIOIscsi backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderBackendDellEMCXTREMIOIscsi: ../puppet/services/cinder-backend-dellemc-xtremio-iscsi.yaml + OS::TripleO::Services::CinderBackendDellEMCXTREMIOIscsi: ../deployment/cinder/cinder-backend-dellemc-xtremio-iscsi-puppet.yaml parameter_defaults: CinderEnableDellEMCXTREMIOIscsiBackend: true diff --git a/environments/cinder-dellps-config.yaml b/environments/cinder-dellps-config.yaml index f5adbafa57..8a28730a8b 100644 --- a/environments/cinder-dellps-config.yaml +++ b/environments/cinder-dellps-config.yaml @@ -15,7 +15,7 @@ # A Heat environment file which can be used to enable a # a Cinder Dell EMC PS Series backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderBackendDellPs: ../puppet/services/cinder-backend-dellps.yaml + OS::TripleO::Services::CinderBackendDellPs: ../deployment/cinder/cinder-backend-dellps-puppet.yaml parameter_defaults: CinderEnableDellPsBackend: true diff --git a/environments/cinder-dellsc-config.yaml b/environments/cinder-dellsc-config.yaml index 1aa2591ae9..10b1ec14ac 100644 --- a/environments/cinder-dellsc-config.yaml +++ b/environments/cinder-dellsc-config.yaml @@ -1,7 +1,7 @@ # A Heat environment file which can be used to enable a # Cinder Dell EMC Storage Center ISCSI backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderBackendDellSc: ../puppet/services/cinder-backend-dellsc.yaml + OS::TripleO::Services::CinderBackendDellSc: ../deployment/cinder/cinder-backend-dellsc-puppet.yaml parameter_defaults: CinderEnableDellScBackend: true diff --git a/environments/cinder-hpelefthand-config.yaml b/environments/cinder-hpelefthand-config.yaml index 90d0261e52..093374a5a2 100644 --- a/environments/cinder-hpelefthand-config.yaml +++ b/environments/cinder-hpelefthand-config.yaml @@ -1,7 +1,7 @@ # A Heat environment file which can be used to enable a # a Cinder HPELeftHandISCSI backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderHPELeftHandISCSI: ../puppet/services/cinder-hpelefthand-iscsi.yaml + OS::TripleO::Services::CinderHPELeftHandISCSI: ../deployment/cinder/cinder-hpelefthand-iscsi-puppet.yaml parameter_defaults: CinderHPELeftHandISCSIApiUrl: '' diff --git a/environments/cinder-netapp-config.yaml b/environments/cinder-netapp-config.yaml index dfd1589395..37aa233caf 100644 --- a/environments/cinder-netapp-config.yaml +++ b/environments/cinder-netapp-config.yaml @@ -1,7 +1,7 @@ # A Heat environment file which can be used to enable a # a Cinder NetApp backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderBackendNetApp: ../puppet/services/cinder-backend-netapp.yaml + OS::TripleO::Services::CinderBackendNetApp: ../deployment/cinder/cinder-backend-netapp-puppet.yaml parameter_defaults: CinderEnableNetappBackend: true diff --git a/environments/cinder-nvmeof-config.yaml b/environments/cinder-nvmeof-config.yaml index 44ca7433ea..a14e2b6fd3 100644 --- a/environments/cinder-nvmeof-config.yaml +++ b/environments/cinder-nvmeof-config.yaml @@ -1,7 +1,7 @@ # A Heat environment file which can be used to enable a # Cinder NVMeOF backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderBackendNVMeOF: ../puppet/services/cinder-backend-nvmeof.yaml + OS::TripleO::Services::CinderBackendNVMeOF: ../deployment/cinder/cinder-backend-nvmeof-puppet.yaml parameter_defaults: CinderNVMeOFBackendName: 'tripleo_nvmeof' diff --git a/environments/cinder-pure-config.yaml b/environments/cinder-pure-config.yaml index 84820d1748..a683989279 100644 --- a/environments/cinder-pure-config.yaml +++ b/environments/cinder-pure-config.yaml @@ -1,7 +1,7 @@ # A Heat environment file which can be used to enable a # Cinder Pure Storage FlashArray iSCSI backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderBackendPure: ../puppet/services/cinder-backend-pure.yaml + OS::TripleO::Services::CinderBackendPure: ../deployment/cinder/cinder-backend-pure-puppet.yaml parameter_defaults: CinderEnablePureBackend: true diff --git a/environments/cinder-scaleio-config.yaml b/environments/cinder-scaleio-config.yaml index 7d99446d40..75086458c2 100644 --- a/environments/cinder-scaleio-config.yaml +++ b/environments/cinder-scaleio-config.yaml @@ -15,7 +15,7 @@ # A Heat environment file which can be used to enable a # a Cinder Dell EMC ScaleIO backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderBackendScaleIO: ../puppet/services/cinder-backend-scaleio.yaml + OS::TripleO::Services::CinderBackendScaleIO: ../deployment/cinder/cinder-backend-scaleio-puppet.yaml parameter_defaults: CinderEnableScaleIOBackend: true diff --git a/environments/docker-ha.yaml b/environments/docker-ha.yaml index f5f09bf910..95096971ea 100644 --- a/environments/docker-ha.yaml +++ b/environments/docker-ha.yaml @@ -14,7 +14,7 @@ resource_registry: OS::TripleO::Services::Keepalived: OS::Heat::None # HA Containers managed by pacemaker - OS::TripleO::Services::CinderVolume: ../docker/services/pacemaker/cinder-volume.yaml + OS::TripleO::Services::CinderVolume: ../deployment/cinder/cinder-volume-pacemaker-puppet.yaml OS::TripleO::Services::Clustercheck: ../docker/services/pacemaker/clustercheck.yaml OS::TripleO::Services::HAproxy: ../docker/services/pacemaker/haproxy.yaml OS::TripleO::Services::MySQL: ../docker/services/pacemaker/database/mysql.yaml diff --git a/environments/nonha-arch.yaml b/environments/nonha-arch.yaml index 99f0f84508..f03b293bb3 100644 --- a/environments/nonha-arch.yaml +++ b/environments/nonha-arch.yaml @@ -1,7 +1,7 @@ # An environment which creates an Overcloud without the use of pacemaker # (i.e. only with keepalived and systemd for all resources) resource_registry: - OS::TripleO::Services::CinderVolume: ../docker/services/cinder-volume.yaml + OS::TripleO::Services::CinderVolume: ../deployment/cinder/cinder-volume-container-puppet.yaml OS::TripleO::Services::RabbitMQ: ../docker/services/rabbitmq.yaml OS::TripleO::Services::HAproxy: ../docker/services/haproxy.yaml OS::TripleO::Services::Redis: ../docker/services/database/redis.yaml diff --git a/environments/services-baremetal/cinder-backup.yaml b/environments/services-baremetal/cinder-backup.yaml index cfea4b4750..3e4ca161f5 100644 --- a/environments/services-baremetal/cinder-backup.yaml +++ b/environments/services-baremetal/cinder-backup.yaml @@ -1,4 +1,4 @@ resource_registry: - OS::TripleO::Services::CinderBackup: ../../puppet/services/pacemaker/cinder-backup.yaml + OS::TripleO::Services::CinderBackup: ../../deployment/cinder/cinder-backup-pacemaker-puppet.yaml # For non-pcmk managed implementation - # OS::TripleO::Services::CinderBackup: ../../puppet/services/cinder-backup.yaml + # OS::TripleO::Services::CinderBackup: ../../deployment/cinder/cinder-backup-container-puppet.yaml diff --git a/environments/services-baremetal/undercloud-cinder.yaml b/environments/services-baremetal/undercloud-cinder.yaml index 69ec27deec..e00e405680 100644 --- a/environments/services-baremetal/undercloud-cinder.yaml +++ b/environments/services-baremetal/undercloud-cinder.yaml @@ -1,4 +1,4 @@ resource_registry: - OS::TripleO::Services::UndercloudCinderApi: ../../puppet/services/cinder-api.yaml - OS::TripleO::Services::UndercloudCinderScheduler: ../../puppet/services/cinder-scheduler.yaml - OS::TripleO::Services::UndercloudCinderVolume: ../../puppet/services/cinder-volume.yaml + OS::TripleO::Services::UndercloudCinderApi: ../../deployment/cinder/cinder-api-container-puppet.yaml + OS::TripleO::Services::UndercloudCinderScheduler: ../../deployment/cinder/cinder-scheduler-container-puppet.yaml + OS::TripleO::Services::UndercloudCinderVolume: ../../deployment/cinder/cinder-volume-container-puppet.yaml diff --git a/environments/services/cinder-backup.yaml b/environments/services/cinder-backup.yaml index fb53a8526f..3e4ca161f5 100644 --- a/environments/services/cinder-backup.yaml +++ b/environments/services/cinder-backup.yaml @@ -1,4 +1,4 @@ resource_registry: - OS::TripleO::Services::CinderBackup: ../../docker/services/pacemaker/cinder-backup.yaml + OS::TripleO::Services::CinderBackup: ../../deployment/cinder/cinder-backup-pacemaker-puppet.yaml # For non-pcmk managed implementation - # OS::TripleO::Services::CinderBackup: ../../docker/services/cinder-backup.yaml + # OS::TripleO::Services::CinderBackup: ../../deployment/cinder/cinder-backup-container-puppet.yaml diff --git a/environments/services/undercloud-cinder.yaml b/environments/services/undercloud-cinder.yaml index a46359b93f..27314ac39b 100644 --- a/environments/services/undercloud-cinder.yaml +++ b/environments/services/undercloud-cinder.yaml @@ -1,6 +1,6 @@ # DEPRECATED. This file will be removed in the Stein release as it is no longer # needed resource_registry: - OS::TripleO::Services::CinderApi: ../../docker/services/cinder-api.yaml - OS::TripleO::Services::CinderScheduler: ../../docker/services/cinder-scheduler.yaml - OS::TripleO::Services::CinderVolume: ../../docker/services/cinder-volume.yaml + OS::TripleO::Services::CinderApi: ../../deployment/cinder/cinder-api-container-puppet.yaml + OS::TripleO::Services::CinderScheduler: ../../deployment/cinder/cinder-scheduler-container-puppet.yaml + OS::TripleO::Services::CinderVolume: ../../deployment/cinder/cinder-volume-container-puppet.yaml diff --git a/environments/storage/cinder-netapp-config.yaml b/environments/storage/cinder-netapp-config.yaml index 5375c67549..88ed13b259 100644 --- a/environments/storage/cinder-netapp-config.yaml +++ b/environments/storage/cinder-netapp-config.yaml @@ -128,4 +128,4 @@ parameter_defaults: # End static parameters # ********************* resource_registry: - OS::TripleO::Services::CinderBackendNetApp: ../puppet/services/cinder-backend-netapp.yaml + OS::TripleO::Services::CinderBackendNetApp: ../deployment/cinder/cinder-backend-netapp-puppet.yaml diff --git a/environments/veritas-hyperscale/cinder-veritas-hyperscale-config.yaml b/environments/veritas-hyperscale/cinder-veritas-hyperscale-config.yaml index eaa6cf7f21..4cae7e871b 100644 --- a/environments/veritas-hyperscale/cinder-veritas-hyperscale-config.yaml +++ b/environments/veritas-hyperscale/cinder-veritas-hyperscale-config.yaml @@ -15,4 +15,4 @@ # A Heat environment file which can be used to enable a # a Veritas HyperScale backend, configured via puppet resource_registry: - OS::TripleO::Services::CinderBackendVRTSHyperScale: ../../puppet/services/cinder-backend-veritas-hyperscale.yaml + OS::TripleO::Services::CinderBackendVRTSHyperScale: ../../deployment/cinder/cinder-backend-veritas-hyperscale-puppet.yaml diff --git a/overcloud-resource-registry-puppet.j2.yaml b/overcloud-resource-registry-puppet.j2.yaml index f0ce520bbc..85f8cc51d0 100644 --- a/overcloud-resource-registry-puppet.j2.yaml +++ b/overcloud-resource-registry-puppet.j2.yaml @@ -115,11 +115,11 @@ resource_registry: OS::TripleO::Services::CephClient: OS::Heat::None OS::TripleO::Services::CephNfs: OS::Heat::None OS::TripleO::Services::CephExternal: OS::Heat::None - OS::TripleO::Services::CinderApi: docker/services/cinder-api.yaml + OS::TripleO::Services::CinderApi: deployment/cinder/cinder-api-container-puppet.yaml OS::TripleO::Services::CinderBackup: OS::Heat::None - OS::TripleO::Services::CinderScheduler: docker/services/cinder-scheduler.yaml - OS::TripleO::Services::CinderVolume: docker/services/cinder-volume.yaml - OS::TripleO::Services::BlockStorageCinderVolume: docker/services/cinder-volume.yaml + OS::TripleO::Services::CinderScheduler: deployment/cinder/cinder-scheduler-container-puppet.yaml + OS::TripleO::Services::CinderVolume: deployment/cinder/cinder-volume-container-puppet.yaml + OS::TripleO::Services::BlockStorageCinderVolume: deployment/cinder/cinder-volume-container-puppet.yaml OS::TripleO::Services::Congress: OS::Heat::None OS::TripleO::Services::Keystone: deployment/keystone/keystone-container-puppet.yaml OS::TripleO::Services::GlanceApi: deployment/glance/glance-api-container-puppet.yaml diff --git a/puppet/services/cinder-api.yaml b/puppet/services/cinder-api.yaml deleted file mode 100644 index 06bbe43c73..0000000000 --- a/puppet/services/cinder-api.yaml +++ /dev/null @@ -1,197 +0,0 @@ -heat_template_version: rocky - -description: > - OpenStack Cinder API service configured with Puppet - -parameters: - CinderDefaultVolumeType: - default: tripleo - description: The name of Cinder's default volume type. - type: string - CinderEnableDBPurge: - default: true - description: | - Whether to create cron job for purging soft deleted rows in Cinder database. - type: boolean - CinderPassword: - description: The password for the cinder service account, used by cinder-api. - type: string - hidden: true - 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 - KeystoneRegion: - type: string - default: 'regionOne' - description: Keystone region for endpoint - MonitoringSubscriptionCinderApi: - default: 'overcloud-cinder-api' - type: string - CinderApiLoggingSource: - type: json - default: - tag: openstack.cinder.api - path: /var/log/cinder/cinder-api.log - CinderWorkers: - type: string - description: Set the number of workers for cinder::wsgi::apache - default: '%{::os_workers}' - EnableInternalTLS: - type: boolean - default: false - CinderApiPolicies: - description: | - A hash of policies to configure for Cinder API. - e.g. { cinder-context_is_admin: { key: context_is_admin, value: 'role:admin' } } - default: {} - type: json - NotificationDriver: - type: string - default: 'messagingv2' - description: Driver or drivers to handle sending notifications. - -conditions: - cinder_workers_zero: {equals : [{get_param: CinderWorkers}, 0]} - -resources: - - ApacheServiceBase: - type: ./apache.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} - EnableInternalTLS: {get_param: EnableInternalTLS} - - CinderBase: - type: ./cinder-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} - -outputs: - role_data: - description: Role data for the Cinder API role. - value: - service_name: cinder_api - monitoring_subscription: {get_param: MonitoringSubscriptionCinderApi} - config_settings: - map_merge: - - get_attr: [CinderBase, role_data, config_settings] - - get_attr: [ApacheServiceBase, role_data, config_settings] - - cinder::keystone::authtoken::www_authenticate_uri: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]} - cinder::keystone::authtoken::auth_uri: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]} - cinder::keystone::authtoken::auth_url: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix]} - cinder::keystone::authtoken::password: {get_param: CinderPassword} - cinder::keystone::authtoken::project_name: 'service' - cinder::keystone::authtoken::user_domain_name: 'Default' - cinder::keystone::authtoken::project_domain_name: 'Default' - cinder::policy::policies: {get_param: CinderApiPolicies} - cinder::ceilometer::notification_driver: {get_param: NotificationDriver} - cinder::api::default_volume_type: {get_param: CinderDefaultVolumeType} - cinder::api::enable_proxy_headers_parsing: true - - cinder::api::nova_catalog_info: 'compute:nova:internalURL' - # TODO(emilien) move it to puppet-cinder - cinder::config: - DEFAULT/swift_catalog_info: - value: 'object-store:swift:internalURL' - tripleo::profile::base::cinder::cinder_enable_db_purge: {get_param: CinderEnableDBPurge} - tripleo::cinder_api::firewall_rules: - '119 cinder': - dport: - - 8776 - - 13776 - cinder::api::bind_host: - str_replace: - template: - "%{hiera('fqdn_$NETWORK')}" - params: - $NETWORK: {get_param: [ServiceNetMap, CinderApiNetwork]} - cinder::wsgi::apache::ssl: {get_param: EnableInternalTLS} - cinder::api::service_name: 'httpd' - # NOTE: bind IP is found in hiera replacing the network name with the local node IP - # for the given network; replacement examples (eg. for internal_api): - # internal_api -> IP - # internal_api_uri -> [IP] - # internal_api_subnet - > IP/CIDR - cinder::wsgi::apache::bind_host: - str_replace: - template: - "%{hiera('$NETWORK')}" - params: - $NETWORK: {get_param: [ServiceNetMap, CinderApiNetwork]} - - - cinder::wsgi::apache::servername: - str_replace: - template: - "%{hiera('fqdn_$NETWORK')}" - params: - $NETWORK: {get_param: [ServiceNetMap, CinderApiNetwork]} - - - if: - - cinder_workers_zero - - {} - - cinder::wsgi::apache::workers: {get_param: CinderWorkers} - step_config: | - include ::tripleo::profile::base::cinder::api - service_config_settings: - fluentd: - tripleo_fluentd_groups_cinder_api: - - cinder - tripleo_fluentd_sources_cinder_api: - - {get_param: CinderApiLoggingSource} - keystone: - cinder::keystone::auth::tenant: 'service' - cinder::keystone::auth::public_url: {get_param: [EndpointMap, CinderPublic, uri]} - cinder::keystone::auth::internal_url: {get_param: [EndpointMap, CinderInternal, uri]} - cinder::keystone::auth::admin_url: {get_param: [EndpointMap, CinderAdmin, uri]} - cinder::keystone::auth::public_url_v2: {get_param: [EndpointMap, CinderV2Public, uri]} - cinder::keystone::auth::internal_url_v2: {get_param: [EndpointMap, CinderV2Internal, uri]} - cinder::keystone::auth::admin_url_v2: {get_param: [EndpointMap, CinderV2Admin, uri]} - cinder::keystone::auth::public_url_v3: {get_param: [EndpointMap, CinderV3Public, uri]} - cinder::keystone::auth::internal_url_v3: {get_param: [EndpointMap, CinderV3Internal, uri]} - cinder::keystone::auth::admin_url_v3: {get_param: [EndpointMap, CinderV3Admin, uri]} - cinder::keystone::auth::password: {get_param: CinderPassword} - cinder::keystone::auth::region: {get_param: KeystoneRegion} - mysql: - cinder::db::mysql::password: {get_param: CinderPassword} - cinder::db::mysql::user: cinder - cinder::db::mysql::host: {get_param: [EndpointMap, MysqlInternal, host_nobrackets]} - cinder::db::mysql::dbname: cinder - cinder::db::mysql::allowed_hosts: - - '%' - - "%{hiera('mysql_bind_host')}" - metadata_settings: - get_attr: [ApacheServiceBase, role_data, metadata_settings] - upgrade_tasks: [] diff --git a/puppet/services/cinder-backup.yaml b/puppet/services/cinder-backup.yaml deleted file mode 100644 index 99804d930f..0000000000 --- a/puppet/services/cinder-backup.yaml +++ /dev/null @@ -1,114 +0,0 @@ -heat_template_version: rocky - -description: > - OpenStack Cinder Backup service configured with Puppet - -parameters: - CinderBackupBackend: - default: swift - description: The short name of the Cinder Backup backend to use. - type: string - constraints: - - allowed_values: ['swift', 'ceph', 'nfs'] - CinderBackupRbdPoolName: - default: backups - type: string - CephClusterName: - type: string - default: ceph - description: The Ceph cluster name. - constraints: - - allowed_pattern: "[a-zA-Z0-9]+" - description: > - The Ceph cluster name must be at least 1 character and contain only - letters and numbers. - CephClientUserName: - default: openstack - type: string - CinderBackupNfsShare: - default: '' - description: NFS share to be mounted - type: string - CinderBackupNfsMountOptions: - default: '' - description: Mount options passed to the NFS client. See NFS man - page for details. - type: string - 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 - MonitoringSubscriptionCinderBackup: - default: 'overcloud-cinder-backup' - type: string - CinderBackupLoggingSource: - type: json - default: - tag: openstack.cinder.backup - path: /var/log/cinder/cinder-backup.log - -resources: - - CinderBase: - type: ./cinder-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} - -outputs: - role_data: - description: Role data for the Cinder Backup role. - value: - service_name: cinder_backup - monitoring_subscription: {get_param: MonitoringSubscriptionCinderBackup} - config_settings: - map_merge: - - get_attr: [CinderBase, role_data, config_settings] - - cinder::backup::ceph::backup_ceph_user: {get_param: CephClientUserName} - cinder::backup::ceph::backup_ceph_pool: {get_param: CinderBackupRbdPoolName} - cinder::backup::ceph::backup_ceph_conf: - list_join: - - '' - - - '/etc/ceph/' - - {get_param: CephClusterName} - - '.conf' - cinder::backup::swift::backup_swift_container: volumebackups - cinder::backup::nfs::backup_share: {get_param: CinderBackupNfsShare} - cinder::backup::nfs::backup_mount_options: {get_param: CinderBackupNfsMountOptions} - service_config_settings: - fluentd: - tripleo_fluentd_groups_cinder_backup: - - cinder - tripleo_fluentd_sources_cinder_backup: - - {get_param: CinderBackupLoggingSource} - step_config: - str_replace: - template: "include ::tripleo::profile::base::cinder::backup::DRIVER" - params: - DRIVER: {get_param: CinderBackupBackend} diff --git a/puppet/services/cinder-scheduler.yaml b/puppet/services/cinder-scheduler.yaml deleted file mode 100644 index ac51a94986..0000000000 --- a/puppet/services/cinder-scheduler.yaml +++ /dev/null @@ -1,72 +0,0 @@ -heat_template_version: rocky - -description: > - OpenStack Cinder Scheduler 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 - MonitoringSubscriptionCinderScheduler: - default: 'overcloud-cinder-scheduler' - type: string - CinderSchedulerLoggingSource: - type: json - default: - tag: openstack.cinder.scheduler - path: /var/log/cinder/cinder-scheduler.log - -resources: - - CinderBase: - type: ./cinder-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} - -outputs: - role_data: - description: Role data for the Cinder Scheduler role. - value: - service_name: cinder_scheduler - monitoring_subscription: {get_param: MonitoringSubscriptionCinderScheduler} - config_settings: - map_merge: - - get_attr: [CinderBase, role_data, config_settings] - - cinder::scheduler::scheduler_driver: cinder.scheduler.filter_scheduler.FilterScheduler - service_config_settings: - fluentd: - tripleo_fluentd_groups_cinder_scheduler: - - cinder - tripleo_fluentd_sources_cinder_scheduler: - - {get_param: CinderSchedulerLoggingSource} - step_config: | - include ::tripleo::profile::base::cinder::scheduler - upgrade_tasks: [] diff --git a/puppet/services/pacemaker/cinder-backup.yaml b/puppet/services/pacemaker/cinder-backup.yaml deleted file mode 100644 index be02391b31..0000000000 --- a/puppet/services/pacemaker/cinder-backup.yaml +++ /dev/null @@ -1,77 +0,0 @@ -heat_template_version: rocky - -description: > - OpenStack Cinder Backup service with Pacemaker configured with Puppet - -parameters: - CinderBackupBackend: - default: swift - description: The short name of the Cinder Backup backend to use. - type: string - constraints: - - allowed_values: ['swift', 'ceph', 'nfs'] - CinderBackupRbdPoolName: - default: backups - type: string - CephClientUserName: - default: openstack - type: string - 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 - -resources: - - CinderBackupBase: - type: ../cinder-backup.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} - CinderBackupBackend: {get_param: CinderBackupBackend} - CinderBackupRbdPoolName: {get_param: CinderBackupRbdPoolName} - CephClientUserName: {get_param: CephClientUserName} - -outputs: - role_data: - description: Role data for the Cinder Backup role. - value: - service_name: cinder_backup - monitoring_subscription: {get_attr: [CinderBackupBase, role_data, monitoring_subscription]} - config_settings: - map_merge: - - get_attr: [CinderBackupBase, role_data, config_settings] - - cinder::backup::manage_service: false - cinder::backup::enabled: false - service_config_settings: {get_attr: [CinderBackupBase, role_data, service_config_settings]} - step_config: - list_join: - - "\n" - - - get_attr: [CinderBackupBase, role_data, step_config] - - "include ::tripleo::profile::pacemaker::cinder::backup" diff --git a/puppet/services/pacemaker/cinder-volume.yaml b/puppet/services/pacemaker/cinder-volume.yaml deleted file mode 100644 index 3a69b58fd7..0000000000 --- a/puppet/services/pacemaker/cinder-volume.yaml +++ /dev/null @@ -1,73 +0,0 @@ -heat_template_version: rocky - -description: > - OpenStack Cinder Volume service with Pacemaker 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 - -resources: - - CinderVolumeBase: - type: ../cinder-volume.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} - -outputs: - role_data: - description: Role data for the Cinder Volume role. - value: - service_name: cinder_volume - monitoring_subscription: {get_attr: [CinderVolumeBase, role_data, monitoring_subscription]} - config_settings: - map_merge: - - get_attr: [CinderVolumeBase, role_data, config_settings] - - cinder::volume::manage_service: false - cinder::volume::enabled: false - cinder::backend_host: hostgroup - service_config_settings: {get_attr: [CinderVolumeBase, role_data, service_config_settings]} - step_config: - include ::tripleo::profile::pacemaker::cinder::volume - upgrade_tasks: - - name: Stop cinder_volume service (pacemaker) - when: step|int == 1 - pacemaker_resource: - resource: openstack-cinder-volume - state: disable - wait_for_resource: true - post_upgrade_tasks: - - name: Start cinder_volume service (pacemaker) - when: step|int == 1 - pacemaker_resource: - resource: openstack-cinder-volume - state: enable diff --git a/sample-env-generator/storage.yaml b/sample-env-generator/storage.yaml index 8ec9349159..4feb700fbc 100644 --- a/sample-env-generator/storage.yaml +++ b/sample-env-generator/storage.yaml @@ -3,7 +3,7 @@ environments: name: storage/cinder-nfs title: Enable Cinder NFS Backend files: - puppet/services/cinder-volume.yaml: + deployment/cinder/cinder-volume-container-puppet.yaml: parameters: - CinderNfsMountOptions - CinderNfsServers @@ -63,9 +63,9 @@ environments: A Heat environment file which can be used to enable a a Cinder NetApp backend, configured via puppet files: - puppet/services/cinder-backend-netapp.yaml: + deployment/cinder/cinder-backend-netapp-puppet.yaml: parameters: all static: - CinderEnableNetappBackend resource_registry: - OS::TripleO::Services::CinderBackendNetApp: ../puppet/services/cinder-backend-netapp.yaml + OS::TripleO::Services::CinderBackendNetApp: ../deployment/cinder/cinder-backend-netapp-puppet.yaml