From a166ec6bcaae078a4f7ed91feb8e431fe031e0cb Mon Sep 17 00:00:00 2001 From: Damien Ciabrini Date: Mon, 2 Dec 2019 13:01:45 +0100 Subject: [PATCH] HA: minor update of arbitrary container image name HA services get their container image name from a pacemaker resource configuration. This image name is shared between all cluster nodes. To achieve image update without service disruption, a pacemaker resource is configured to use an intermediate image name "//:pcmklatest" pointing to the real image name configured in Heat. This tag can then be updated independently on every node during the minor update. In order to support the same rolling update when the changes in the container image, we need a similar floating approach for the prefix part of the container image. Introduce a new Heat parameter ClusterCommonTag that, when enabled, sets the intermediate image name to "cluster-common-tag/:pcmklatest". By default, this parameter is disabled and the original naming scheme is conserved. Note: by introducing this new naming scheme, we stop seeing a meaningful image name prefix when doing a "pcs status", but since we already can't tell what image ID the :pcmklatest tag points to, we don't lose much information really. Related-Bug: #1854730 Change-Id: Id369154d147cd5cf0a6f997bf806084fc7580e01 --- .../cinder-backup-pacemaker-puppet.yaml | 24 ++++++++++++++----- .../cinder-volume-pacemaker-puppet.yaml | 24 ++++++++++++++----- .../database/mysql-pacemaker-puppet.yaml | 24 ++++++++++++++----- .../database/redis-pacemaker-puppet.yaml | 24 ++++++++++++++----- .../haproxy/haproxy-pacemaker-puppet.yaml | 24 ++++++++++++++----- .../manila/manila-share-pacemaker-puppet.yaml | 24 ++++++++++++++----- deployment/ovn/ovn-dbs-pacemaker-puppet.yaml | 24 ++++++++++++++----- ...tmq-messaging-notify-pacemaker-puppet.yaml | 24 ++++++++++++++----- .../rabbitmq-messaging-pacemaker-puppet.yaml | 24 ++++++++++++++----- ...bbitmq-messaging-rpc-pacemaker-puppet.yaml | 24 ++++++++++++++----- ...r-cluster-common-tag-45c4e8a6e7b08735.yaml | 12 ++++++++++ 11 files changed, 192 insertions(+), 60 deletions(-) create mode 100644 releasenotes/notes/pacemaker-cluster-common-tag-45c4e8a6e7b08735.yaml diff --git a/deployment/cinder/cinder-backup-pacemaker-puppet.yaml b/deployment/cinder/cinder-backup-pacemaker-puppet.yaml index d27fe397d4..4af07eae3e 100644 --- a/deployment/cinder/cinder-backup-pacemaker-puppet.yaml +++ b/deployment/cinder/cinder-backup-pacemaker-puppet.yaml @@ -10,6 +10,14 @@ parameters: ContainerCinderConfigImage: description: The container image to use for the cinder config_volume type: string + ClusterCommonTag: + default: false + description: When set to false, a pacemaker service is configured + to use a floating tag for its container image name, + e.g. 'REGISTRY/NAMESPACE/IMAGENAME:pcmklatest'. When + set to true, the service uses a floating prefix as + well, e.g. 'cluster-common-tag/IMAGENAME:pcmklatest'. + type: boolean CinderBackupBackend: default: swift description: The short name of the Cinder Backup backend to use. @@ -73,6 +81,7 @@ parameters: conditions: puppet_debug_enabled: {get_param: ConfigDebug} docker_enabled: {equals: [{get_param: ContainerCli}, 'docker']} + common_tag_enabled: {equals: [{get_param: ClusterCommonTag}, true]} resources: @@ -108,12 +117,15 @@ outputs: map_merge: - get_attr: [CinderBackupBase, role_data, config_settings] - tripleo::profile::pacemaker::cinder::backup_bundle::cinder_backup_docker_image: &cinder_backup_image_pcmklatest - list_join: - - ':' - - - yaql: - data: {get_param: ContainerCinderBackupImage} - expression: $.data.rightSplit(separator => ":", maxSplits => 1)[0] - - 'pcmklatest' + yaql: + data: + if: + - common_tag_enabled + - yaql: + data: {get_param: ContainerCinderBackupImage} + expression: concat("cluster-common-tag/", $.data.rightSplit(separator => "/", maxSplits => 1)[1]) + - {get_param: ContainerCinderBackupImage} + expression: concat($.data.rightSplit(separator => ":", maxSplits => 1)[0], ":pcmklatest") tripleo::profile::pacemaker::cinder::backup_bundle::docker_volumes: {get_attr: [CinderCommon, cinder_backup_volumes]} tripleo::profile::pacemaker::cinder::backup_bundle::docker_environment: {get_attr: [CinderCommon, cinder_backup_environment]} tripleo::profile::pacemaker::cinder::backup_bundle::container_backend: {get_param: ContainerCli} diff --git a/deployment/cinder/cinder-volume-pacemaker-puppet.yaml b/deployment/cinder/cinder-volume-pacemaker-puppet.yaml index 7ff97a4f68..f6727bb5ad 100644 --- a/deployment/cinder/cinder-volume-pacemaker-puppet.yaml +++ b/deployment/cinder/cinder-volume-pacemaker-puppet.yaml @@ -10,6 +10,14 @@ parameters: ContainerCinderConfigImage: description: The container image to use for the cinder config_volume type: string + ClusterCommonTag: + default: false + description: When set to false, a pacemaker service is configured + to use a floating tag for its container image name, + e.g. 'REGISTRY/NAMESPACE/IMAGENAME:pcmklatest'. When + set to true, the service uses a floating prefix as + well, e.g. 'cluster-common-tag/IMAGENAME:pcmklatest'. + type: boolean EndpointMap: default: {} description: Mapping of service endpoint -> protocol. Typically set @@ -61,6 +69,7 @@ parameters: conditions: puppet_debug_enabled: {get_param: ConfigDebug} docker_enabled: {equals: [{get_param: ContainerCli}, 'docker']} + common_tag_enabled: {equals: [{get_param: ClusterCommonTag}, true]} resources: @@ -94,12 +103,15 @@ outputs: - get_attr: [CinderBase, role_data, config_settings] - tripleo::profile::base::lvm::enable_udev: false tripleo::profile::pacemaker::cinder::volume_bundle::cinder_volume_docker_image: &cinder_volume_image_pcmklatest - list_join: - - ':' - - - yaql: - data: {get_param: ContainerCinderVolumeImage} - expression: $.data.rightSplit(separator => ":", maxSplits => 1)[0] - - 'pcmklatest' + yaql: + data: + if: + - common_tag_enabled + - yaql: + data: {get_param: ContainerCinderVolumeImage} + expression: concat("cluster-common-tag/", $.data.rightSplit(separator => "/", maxSplits => 1)[1]) + - {get_param: ContainerCinderVolumeImage} + expression: concat($.data.rightSplit(separator => ":", maxSplits => 1)[0], ":pcmklatest") tripleo::profile::pacemaker::cinder::volume_bundle::docker_volumes: {get_attr: [CinderCommon, cinder_volume_volumes]} tripleo::profile::pacemaker::cinder::volume_bundle::docker_environment: {get_attr: [CinderCommon, cinder_volume_environment]} tripleo::profile::pacemaker::cinder::volume_bundle::container_backend: {get_param: ContainerCli} diff --git a/deployment/database/mysql-pacemaker-puppet.yaml b/deployment/database/mysql-pacemaker-puppet.yaml index 7e6ac40890..725dc5131a 100644 --- a/deployment/database/mysql-pacemaker-puppet.yaml +++ b/deployment/database/mysql-pacemaker-puppet.yaml @@ -10,6 +10,14 @@ parameters: ContainerMysqlConfigImage: description: The container image to use for the mysql config_volume type: string + ClusterCommonTag: + default: false + description: When set to false, a pacemaker service is configured + to use a floating tag for its container image name, + e.g. 'REGISTRY/NAMESPACE/IMAGENAME:pcmklatest'. When + set to true, the service uses a floating prefix as + well, e.g. 'cluster-common-tag/IMAGENAME:pcmklatest'. + type: boolean EndpointMap: default: {} description: Mapping of service endpoint -> protocol. Typically set @@ -93,6 +101,7 @@ conditions: puppet_debug_enabled: {get_param: ConfigDebug} internal_tls_enabled: {equals: [{get_param: EnableInternalTLS}, true]} docker_enabled: {equals: [{get_param: ContainerCli}, 'docker']} + common_tag_enabled: {equals: [{get_param: ClusterCommonTag}, true]} outputs: role_data: @@ -133,12 +142,15 @@ outputs: tripleo::profile::pacemaker::database::mysql::ca_file: get_param: InternalTLSCAFile tripleo::profile::pacemaker::database::mysql_bundle::mysql_docker_image: &mysql_image_pcmklatest - list_join: - - ':' - - - yaql: - data: {get_param: ContainerMysqlImage} - expression: $.data.rightSplit(separator => ":", maxSplits => 1)[0] - - 'pcmklatest' + yaql: + data: + if: + - common_tag_enabled + - yaql: + data: {get_param: ContainerMysqlImage} + expression: concat("cluster-common-tag/", $.data.rightSplit(separator => "/", maxSplits => 1)[1]) + - {get_param: ContainerMysqlImage} + expression: concat($.data.rightSplit(separator => ":", maxSplits => 1)[0], ":pcmklatest") tripleo::profile::pacemaker::database::mysql_bundle::control_port: 3123 tripleo::profile::pacemaker::database::mysql_bundle::container_backend: {get_param: ContainerCli} tripleo::profile::pacemaker::database::mysql_bundle::bind_address: diff --git a/deployment/database/redis-pacemaker-puppet.yaml b/deployment/database/redis-pacemaker-puppet.yaml index b94a635324..4bbf8ab639 100644 --- a/deployment/database/redis-pacemaker-puppet.yaml +++ b/deployment/database/redis-pacemaker-puppet.yaml @@ -10,6 +10,14 @@ parameters: ContainerRedisConfigImage: description: The container image to use for the redis config_volume type: string + ClusterCommonTag: + default: false + description: When set to false, a pacemaker service is configured + to use a floating tag for its container image name, + e.g. 'REGISTRY/NAMESPACE/IMAGENAME:pcmklatest'. When + set to true, the service uses a floating prefix as + well, e.g. 'cluster-common-tag/IMAGENAME:pcmklatest'. + type: boolean EndpointMap: default: {} description: Mapping of service endpoint -> protocol. Typically set @@ -65,6 +73,7 @@ conditions: internal_tls_enabled: {equals: [{get_param: EnableInternalTLS}, true]} redis_ipv6: {get_param: RedisIPv6} docker_enabled: {equals: [{get_param: ContainerCli}, 'docker']} + common_tag_enabled: {equals: [{get_param: ClusterCommonTag}, true]} resources: @@ -99,12 +108,15 @@ outputs: redis::notify_service: false redis::managed_by_cluster_manager: true tripleo::profile::pacemaker::database::redis_bundle::redis_docker_image: &redis_image_pcmklatest - list_join: - - ':' - - - yaql: - data: {get_param: ContainerRedisImage} - expression: $.data.rightSplit(separator => ":", maxSplits => 1)[0] - - 'pcmklatest' + yaql: + data: + if: + - common_tag_enabled + - yaql: + data: {get_param: ContainerRedisImage} + expression: concat("cluster-common-tag/", $.data.rightSplit(separator => "/", maxSplits => 1)[1]) + - {get_param: ContainerRedisImage} + expression: concat($.data.rightSplit(separator => ":", maxSplits => 1)[0], ":pcmklatest") tripleo::profile::pacemaker::database::redis_bundle::control_port: 3124 tripleo::profile::pacemaker::database::redis_bundle::container_backend: {get_param: ContainerCli} tripleo::stunnel::manage_service: false diff --git a/deployment/haproxy/haproxy-pacemaker-puppet.yaml b/deployment/haproxy/haproxy-pacemaker-puppet.yaml index 7a13e515de..bb58304415 100644 --- a/deployment/haproxy/haproxy-pacemaker-puppet.yaml +++ b/deployment/haproxy/haproxy-pacemaker-puppet.yaml @@ -10,6 +10,14 @@ parameters: ContainerHAProxyConfigImage: description: The container image to use for the haproxy config_volume type: string + ClusterCommonTag: + default: false + description: When set to false, a pacemaker service is configured + to use a floating tag for its container image name, + e.g. 'REGISTRY/NAMESPACE/IMAGENAME:pcmklatest'. When + set to true, the service uses a floating prefix as + well, e.g. 'cluster-common-tag/IMAGENAME:pcmklatest'. + type: boolean ServiceData: default: {} description: Dictionary packing service data @@ -110,6 +118,7 @@ conditions: - true internal_tls_enabled: {equals: [{get_param: EnableInternalTLS}, true]} docker_enabled: {equals: [{get_param: ContainerCli}, 'docker']} + common_tag_enabled: {equals: [{get_param: ClusterCommonTag}, true]} resources: @@ -176,12 +185,15 @@ outputs: # disable the use CRL file until we can restart the container when the file expires tripleo::haproxy::crl_file: null tripleo::profile::pacemaker::haproxy_bundle::haproxy_docker_image: &haproxy_image_pcmklatest - list_join: - - ':' - - - yaql: - data: {get_param: ContainerHAProxyImage} - expression: $.data.rightSplit(separator => ":", maxSplits => 1)[0] - - 'pcmklatest' + yaql: + data: + if: + - common_tag_enabled + - yaql: + data: {get_param: ContainerHAProxyImage} + expression: concat("cluster-common-tag/", $.data.rightSplit(separator => "/", maxSplits => 1)[1]) + - {get_param: ContainerHAProxyImage} + expression: concat($.data.rightSplit(separator => ":", maxSplits => 1)[0], ":pcmklatest") # BEGIN DOCKER SETTINGS puppet_config: config_volume: haproxy diff --git a/deployment/manila/manila-share-pacemaker-puppet.yaml b/deployment/manila/manila-share-pacemaker-puppet.yaml index e93db13971..cf27b17f03 100644 --- a/deployment/manila/manila-share-pacemaker-puppet.yaml +++ b/deployment/manila/manila-share-pacemaker-puppet.yaml @@ -10,6 +10,14 @@ parameters: ContainerManilaConfigImage: description: image type: string + ClusterCommonTag: + default: false + description: When set to false, a pacemaker service is configured + to use a floating tag for its container image name, + e.g. 'REGISTRY/NAMESPACE/IMAGENAME:pcmklatest'. When + set to true, the service uses a floating prefix as + well, e.g. 'cluster-common-tag/IMAGENAME:pcmklatest'. + type: boolean EndpointMap: default: {} description: Mapping of service endpoint -> protocol. Typically set @@ -56,6 +64,7 @@ parameters: conditions: puppet_debug_enabled: {get_param: ConfigDebug} docker_enabled: {equals: [{get_param: ContainerCli}, 'docker']} + common_tag_enabled: {equals: [{get_param: ClusterCommonTag}, true]} resources: @@ -87,12 +96,15 @@ outputs: map_merge: - get_attr: [ManilaShareContainerBase, role_data, config_settings] - tripleo::profile::pacemaker::manila::share_bundle::manila_share_docker_image: &manila_share_image_pcmklatest - list_join: - - ':' - - - yaql: - data: {get_param: ContainerManilaShareImage} - expression: $.data.rightSplit(separator => ":", maxSplits => 1)[0] - - 'pcmklatest' + yaql: + data: + if: + - common_tag_enabled + - yaql: + data: {get_param: ContainerManilaShareImage} + expression: concat("cluster-common-tag/", $.data.rightSplit(separator => "/", maxSplits => 1)[1]) + - {get_param: ContainerManilaShareImage} + expression: concat($.data.rightSplit(separator => ":", maxSplits => 1)[0], ":pcmklatest") tripleo::profile::pacemaker::manila::share_bundle::docker_volumes: {get_attr: [ManilaCommon, manila_share_volumes]} tripleo::profile::pacemaker::manila::share_bundle::docker_environment: {get_attr: [ManilaCommon, manila_share_environment]} tripleo::profile::pacemaker::manila::share_bundle::container_backend: {get_param: ContainerCli} diff --git a/deployment/ovn/ovn-dbs-pacemaker-puppet.yaml b/deployment/ovn/ovn-dbs-pacemaker-puppet.yaml index 371c8a94c1..9b3601a312 100644 --- a/deployment/ovn/ovn-dbs-pacemaker-puppet.yaml +++ b/deployment/ovn/ovn-dbs-pacemaker-puppet.yaml @@ -10,6 +10,14 @@ parameters: ContainerOvnDbsConfigImage: description: image type: string + ClusterCommonTag: + default: false + description: When set to false, a pacemaker service is configured + to use a floating tag for its container image name, + e.g. 'REGISTRY/NAMESPACE/IMAGENAME:pcmklatest'. When + set to true, the service uses a floating prefix as + well, e.g. 'cluster-common-tag/IMAGENAME:pcmklatest'. + type: boolean EndpointMap: default: {} description: Mapping of service endpoint -> protocol. Typically set @@ -78,6 +86,7 @@ conditions: puppet_debug_enabled: {get_param: ConfigDebug} docker_enabled: {equals: [{get_param: ContainerCli}, 'docker']} internal_tls_enabled: {equals: [{get_param: EnableInternalTLS}, true]} + common_tag_enabled: {equals: [{get_param: ClusterCommonTag}, true]} resources: @@ -113,12 +122,15 @@ outputs: map_merge: - get_attr: [OVNDbsBase, role_data, config_settings] - tripleo::profile::pacemaker::ovn_dbs_bundle::ovn_dbs_docker_image: &ovn_dbs_image_pcmklatest - list_join: - - ':' - - - yaql: - data: {get_param: ContainerOvnDbsImage} - expression: $.data.rightSplit(separator => ":", maxSplits => 1)[0] - - 'pcmklatest' + yaql: + data: + if: + - common_tag_enabled + - yaql: + data: {get_param: ContainerOvnDbsImage} + expression: concat("cluster-common-tag/", $.data.rightSplit(separator => "/", maxSplits => 1)[1]) + - {get_param: ContainerOvnDbsImage} + expression: concat($.data.rightSplit(separator => ":", maxSplits => 1)[0], ":pcmklatest") - tripleo::profile::pacemaker::ovn_dbs_bundle::nb_db_port: {get_param: OVNNorthboundServerPort} - tripleo::profile::pacemaker::ovn_dbs_bundle::sb_db_port: {get_param: OVNSouthboundServerPort} - tripleo::profile::pacemaker::ovn_dbs_bundle::container_backend: {get_param: ContainerCli} diff --git a/deployment/rabbitmq/rabbitmq-messaging-notify-pacemaker-puppet.yaml b/deployment/rabbitmq/rabbitmq-messaging-notify-pacemaker-puppet.yaml index 1640b33c9d..aa977dd5e4 100644 --- a/deployment/rabbitmq/rabbitmq-messaging-notify-pacemaker-puppet.yaml +++ b/deployment/rabbitmq/rabbitmq-messaging-notify-pacemaker-puppet.yaml @@ -10,6 +10,14 @@ parameters: ContainerRabbitmqConfigImage: description: The container image to use for the rabbitmq config_volume type: string + ClusterCommonTag: + default: false + description: When set to false, a pacemaker service is configured + to use a floating tag for its container image name, + e.g. 'REGISTRY/NAMESPACE/IMAGENAME:pcmklatest'. When + set to true, the service uses a floating prefix as + well, e.g. 'cluster-common-tag/IMAGENAME:pcmklatest'. + type: boolean EndpointMap: default: {} description: Mapping of service endpoint -> protocol. Typically set @@ -60,6 +68,7 @@ parameters: conditions: puppet_debug_enabled: {get_param: ConfigDebug} docker_enabled: {equals: [{get_param: ContainerCli}, 'docker']} + common_tag_enabled: {equals: [{get_param: ClusterCommonTag}, true]} resources: @@ -94,12 +103,15 @@ outputs: - {get_attr: [RabbitmqBase, role_data, config_settings]} - rabbitmq::service_manage: false tripleo::profile::pacemaker::rabbitmq_bundle::rabbitmq_docker_image: &rabbitmq_image_pcmklatest - list_join: - - ':' - - - yaql: - data: {get_param: ContainerRabbitmqImage} - expression: $.data.rightSplit(separator => ":", maxSplits => 1)[0] - - 'pcmklatest' + yaql: + data: + if: + - common_tag_enabled + - yaql: + data: {get_param: ContainerRabbitmqImage} + expression: concat("cluster-common-tag/", $.data.rightSplit(separator => "/", maxSplits => 1)[1]) + - {get_param: ContainerRabbitmqImage} + expression: concat($.data.rightSplit(separator => ":", maxSplits => 1)[0], ":pcmklatest") tripleo::profile::pacemaker::rabbitmq_bundle::control_port: 3122 tripleo::profile::pacemaker::rabbitmq_bundle::container_backend: {get_param: ContainerCli} service_config_settings: {get_attr: [RabbitmqBase, role_data, service_config_settings]} diff --git a/deployment/rabbitmq/rabbitmq-messaging-pacemaker-puppet.yaml b/deployment/rabbitmq/rabbitmq-messaging-pacemaker-puppet.yaml index 02034cb6fe..a0673d19f7 100644 --- a/deployment/rabbitmq/rabbitmq-messaging-pacemaker-puppet.yaml +++ b/deployment/rabbitmq/rabbitmq-messaging-pacemaker-puppet.yaml @@ -10,6 +10,14 @@ parameters: ContainerRabbitmqConfigImage: description: The container image to use for the rabbitmq config_volume type: string + ClusterCommonTag: + default: false + description: When set to false, a pacemaker service is configured + to use a floating tag for its container image name, + e.g. 'REGISTRY/NAMESPACE/IMAGENAME:pcmklatest'. When + set to true, the service uses a floating prefix as + well, e.g. 'cluster-common-tag/IMAGENAME:pcmklatest'. + type: boolean EndpointMap: default: {} description: Mapping of service endpoint -> protocol. Typically set @@ -60,6 +68,7 @@ parameters: conditions: puppet_debug_enabled: {get_param: ConfigDebug} docker_enabled: {equals: [{get_param: ContainerCli}, 'docker']} + common_tag_enabled: {equals: [{get_param: ClusterCommonTag}, true]} resources: @@ -94,12 +103,15 @@ outputs: - get_attr: [RabbitMQServiceBase, role_data, config_settings] - rabbitmq::service_manage: false tripleo::profile::pacemaker::rabbitmq_bundle::rabbitmq_docker_image: &rabbitmq_image_pcmklatest - list_join: - - ':' - - - yaql: - data: {get_param: ContainerRabbitmqImage} - expression: $.data.rightSplit(separator => ":", maxSplits => 1)[0] - - 'pcmklatest' + yaql: + data: + if: + - common_tag_enabled + - yaql: + data: {get_param: ContainerRabbitmqImage} + expression: concat("cluster-common-tag/", $.data.rightSplit(separator => "/", maxSplits => 1)[1]) + - {get_param: ContainerRabbitmqImage} + expression: concat($.data.rightSplit(separator => ":", maxSplits => 1)[0], ":pcmklatest") tripleo::profile::pacemaker::rabbitmq_bundle::control_port: 3122 tripleo::profile::pacemaker::rabbitmq_bundle::container_backend: {get_param: ContainerCli} service_config_settings: {get_attr: [RabbitmqBase, role_data, service_config_settings]} diff --git a/deployment/rabbitmq/rabbitmq-messaging-rpc-pacemaker-puppet.yaml b/deployment/rabbitmq/rabbitmq-messaging-rpc-pacemaker-puppet.yaml index ebd094dafb..bb2c699785 100644 --- a/deployment/rabbitmq/rabbitmq-messaging-rpc-pacemaker-puppet.yaml +++ b/deployment/rabbitmq/rabbitmq-messaging-rpc-pacemaker-puppet.yaml @@ -10,6 +10,14 @@ parameters: ContainerRabbitmqConfigImage: description: The container image to use for the rabbitmq config_volume type: string + ClusterCommonTag: + default: false + description: When set to false, a pacemaker service is configured + to use a floating tag for its container image name, + e.g. 'REGISTRY/NAMESPACE/IMAGENAME:pcmklatest'. When + set to true, the service uses a floating prefix as + well, e.g. 'cluster-common-tag/IMAGENAME:pcmklatest'. + type: boolean EndpointMap: default: {} description: Mapping of service endpoint -> protocol. Typically set @@ -60,6 +68,7 @@ parameters: conditions: puppet_debug_enabled: {get_param: ConfigDebug} docker_enabled: {equals: [{get_param: ContainerCli}, 'docker']} + common_tag_enabled: {equals: [{get_param: ClusterCommonTag}, true]} resources: @@ -94,12 +103,15 @@ outputs: - {get_attr: [RabbitmqBase, role_data, config_settings]} - rabbitmq::service_manage: false tripleo::profile::pacemaker::rabbitmq_bundle::rabbitmq_docker_image: &rabbitmq_image_pcmklatest - list_join: - - ':' - - - yaql: - data: {get_param: ContainerRabbitmqImage} - expression: $.data.rightSplit(separator => ":", maxSplits => 1)[0] - - 'pcmklatest' + yaql: + data: + if: + - common_tag_enabled + - yaql: + data: {get_param: ContainerRabbitmqImage} + expression: concat("cluster-common-tag/", $.data.rightSplit(separator => "/", maxSplits => 1)[1]) + - {get_param: ContainerRabbitmqImage} + expression: concat($.data.rightSplit(separator => ":", maxSplits => 1)[0], ":pcmklatest") tripleo::profile::pacemaker::rabbitmq_bundle::control_port: 3122 tripleo::profile::pacemaker::rabbitmq_bundle::container_backend: {get_param: ContainerCli} service_config_settings: {get_attr: [RabbitmqBase, role_data, service_config_settings]} diff --git a/releasenotes/notes/pacemaker-cluster-common-tag-45c4e8a6e7b08735.yaml b/releasenotes/notes/pacemaker-cluster-common-tag-45c4e8a6e7b08735.yaml new file mode 100644 index 0000000000..d16c347a05 --- /dev/null +++ b/releasenotes/notes/pacemaker-cluster-common-tag-45c4e8a6e7b08735.yaml @@ -0,0 +1,12 @@ +--- +features: + - HA services use a special container image name derived from the one + configured in Heat parameter plus a fixed tag part, i.e. + '//:pcmklatest'. To implement rolling + update without service disruption, this 'pcmklatest' tag is adjusted + automatically during minor update every time a new image is pulled. + A new Heat parameter ClusterCommonTag can now control the prefix part + of the container image name. When set to true, the container name + for HA services will look like + 'container-common-tag/:pcmklatest'. This allows rolling + update of HA services even when the changes in Heat.