Merge "Support for Satellite Capsule in rhel-registration" into stable/pike
authorZuul <zuul@review.openstack.org>
Tue, 24 Oct 2017 10:03:13 +0000 (10:03 +0000)
committerGerrit Code Review <review@openstack.org>
Tue, 24 Oct 2017 10:03:13 +0000 (10:03 +0000)
12 files changed:
ci/environments/scenario001-multinode-containers.yaml
deployed-server/deployed-server-roles-data.yaml
docker/docker-puppet.py
docker/services/ceph-ansible/ceph-mon.yaml
docker/services/ceph-ansible/ceph-osd.yaml
docker/services/swift-storage.yaml
environments/services/heat-api-cloudwatch.yaml [new file with mode: 0644]
network/service_net_map.j2.yaml
overcloud-resource-registry-puppet.j2.yaml
puppet/all-nodes-config.j2.yaml [moved from puppet/all-nodes-config.yaml with 92% similarity]
puppet/services/disabled/heat-api-cloudwatch-disabled.yaml [new file with mode: 0644]
releasenotes/notes/disable-heat-api-cloudwatch-d5a471da22472bde.yaml [new file with mode: 0644]

index 8918266..df12bc5 100644 (file)
@@ -101,7 +101,6 @@ parameter_defaults:
     devices:
       - /dev/loop3
     journal_size: 512
-    journal_collocation: true
     osd_scenario: collocated
   CephAnsibleExtraConfig:
     ceph_conf_overrides:
index 877fc7d..8611940 100644 (file)
     - StorageMgmt
     - Tenant
   HostnameFormatDefault: '%stackname%-controller-%index%'
-  # Deprecated & backward-compatible values (FIXME: Make parameters consistent)
-  # Set uses_deprecated_params to True if any deprecated params are used.
-  uses_deprecated_params: True
-  deprecated_param_extraconfig: 'controllerExtraConfig'
-  deprecated_param_flavor: 'OvercloudControlFlavor'
-  deprecated_param_image: 'controllerImage'
   ServicesDefault:
     - OS::TripleO::Services::AodhApi
     - OS::TripleO::Services::AodhEvaluator
     - InternalApi
     - Tenant
     - Storage
-  # Deprecated & backward-compatible values (FIXME: Make parameters consistent)
-  # Set uses_deprecated_params to True if any deprecated params are used.
-  uses_deprecated_params: True
-  deprecated_param_image: 'NovaImage'
-  deprecated_param_extraconfig: 'NovaComputeExtraConfig'
-  deprecated_param_metadata: 'NovaComputeServerMetadata'
-  deprecated_param_scheduler_hints: 'NovaComputeSchedulerHints'
-  deprecated_param_ips: 'NovaComputeIPs'
-  deprecated_server_resource_name: 'NovaCompute'
   ServicesDefault:
     - OS::TripleO::Services::AuditD
     - OS::TripleO::Services::CACerts
     - InternalApi
     - Storage
     - StorageMgmt
-  # Deprecated & backward-compatible values (FIXME: Make parameters consistent)
-  # Set uses_deprecated_params to True if any deprecated params are used.
-  uses_deprecated_params: True
-  deprecated_param_metadata: 'SwiftStorageServerMetadata'
-  deprecated_param_ips: 'SwiftStorageIPs'
-  deprecated_param_image: 'SwiftStorageImage'
-  deprecated_param_flavor: 'OvercloudSwiftStorageFlavor'
   disable_upgrade_deployment: True
   ServicesDefault:
     - OS::TripleO::Services::AuditD
index cc24703..533ed07 100755 (executable)
@@ -90,16 +90,17 @@ def match_config_volume(prefix, config):
     config_volume=None
     for v in volumes:
         if v.startswith(prefix):
-            config_volume =  os.path.relpath(
-                v.split(":")[0], prefix).split("/")[0]
+            config_volume = os.path.dirname(v.split(":")[0])
             break
     return config_volume
 
 
-def get_config_hash(prefix, config_volume):
-    hashfile = os.path.join(prefix, "%s.md5sum" % config_volume)
+def get_config_hash(config_volume):
+    hashfile = "%s.md5sum" % config_volume
+    log.debug("Looking for hashfile %s for config_volume %s" % (hashfile, config_volume))
     hash_data = None
     if os.path.isfile(hashfile):
+        log.debug("Got hashfile %s for config_volume %s" % (hashfile, config_volume))
         with open(hashfile) as f:
             hash_data = f.read().rstrip()
     return hash_data
@@ -248,6 +249,7 @@ def mp_puppet_config((config_volume, puppet_tags, manifest, config_image, volume
             # Write a checksum of the config-data dir, this is used as a
             # salt to trigger container restart when the config changes
             tar -c -f - /var/lib/config-data/${NAME} --mtime='1970-01-01' | md5sum | awk '{print $1}' > /var/lib/config-data/${NAME}.md5sum
+            tar -c -f - /var/lib/config-data/puppet-generated/${NAME} --mtime='1970-01-01' | md5sum | awk '{print $1}' > /var/lib/config-data/puppet-generated/${NAME}.md5sum
         fi
         """)
 
@@ -371,7 +373,7 @@ for infile in infiles:
     for k, v in infile_data.iteritems():
         config_volume = match_config_volume(config_volume_prefix, v)
         if config_volume:
-            config_hash = get_config_hash(config_volume_prefix, config_volume)
+            config_hash = get_config_hash(config_volume)
             if config_hash:
                 env = v.get('environment', [])
                 env.append("TRIPLEO_CONFIG_HASH=%s" % config_hash)
index 45f939c..90b2db3 100644 (file)
@@ -83,4 +83,3 @@ outputs:
             - {get_attr: [CephBase, role_data, config_settings, ceph_common_ansible_vars]}
             - monitor_secret: {get_param: CephMonKey}
               admin_secret: {get_param: CephAdminKey}
-              monitor_interface: br_ex
index a441f5c..de55924 100644 (file)
@@ -37,7 +37,6 @@ parameters:
       devices:
       - /dev/vdb
       journal_size: 512
-      journal_collocation: true
       osd_scenario: collocated
 
 resources:
index e0c1194..2d7aff6 100644 (file)
@@ -83,7 +83,10 @@ outputs:
       logging_source: {get_attr: [SwiftStorageBase, role_data, logging_source]}
       logging_groups: {get_attr: [SwiftStorageBase, role_data, logging_groups]}
       step_config: &step_config
-        get_attr: [SwiftStorageBase, role_data, step_config]
+        list_join:
+          - "\n"
+          - - {get_attr: [SwiftStorageBase, role_data, step_config]}
+            - "class xinetd() {}"
       service_config_settings: {get_attr: [SwiftStorageBase, role_data, service_config_settings]}
       # BEGIN DOCKER SETTINGS
       puppet_config:
diff --git a/environments/services/heat-api-cloudwatch.yaml b/environments/services/heat-api-cloudwatch.yaml
new file mode 100644 (file)
index 0000000..ce22a91
--- /dev/null
@@ -0,0 +1,2 @@
+resource_registry:
+  OS::TripleO::Services::HeatApiCloudwatch: ../../puppet/services/heat-api-cloudwatch.yaml
index e19ccd8..dfb0e91 100644 (file)
@@ -103,31 +103,12 @@ parameters:
                  internal use only, this will be removed in future.
     type: json
 
-  InternalApiNetName:
-    default: internal_api
-    description: The name of the internal_api network.
+{%- for network in networks %}
+  {{network.name}}NetName:
+    default: {{network.name_lower}}
+    description: The name of the {{network.name_lower}} network.
     type: string
-  ExternalNetName:
-    default: external
-    description: The name of the external network.
-    type: string
-  ManagementNetName:
-    default: management
-    description: The name of the management network.
-    type: string
-  StorageNetName:
-    default: storage
-    description: The name of the storage network.
-    type: string
-  StorageMgmtNetName:
-    default: storage_mgmt
-    description: The name of the storage_mgmt network.
-    type: string
-  TenantNetName:
-    default: tenant
-    description: The name of the tenant network.
-    type: string
-
+{%- endfor %}
 
 parameter_groups:
 - label: deprecated
@@ -145,12 +126,9 @@ resources:
           - map_replace:
              - {get_param: ServiceNetMapDefaults}
              - values:
-                 external: {get_param: ExternalNetName}
-                 internal_api: {get_param: InternalApiNetName}
-                 storage: {get_param: StorageNetName}
-                 storage_mgmt: {get_param: StorageMgmtNetName}
-                 tenant: {get_param: TenantNetName}
-                 management: {get_param: ManagementNetName}
+{%- for network in networks %}
+                 {{network.name_lower}}: {get_param: {{network.name}}NetName}
+{%- endfor %}
           - map_replace:
              - {get_param: ServiceNetMap}
              - keys: {get_param: ServiceNetMapDeprecatedMapping}
index e402f12..3ee7721 100644 (file)
@@ -133,7 +133,7 @@ resource_registry:
   OS::TripleO::Services::GlanceRegistry: puppet/services/disabled/glance-registry-disabled.yaml
   OS::TripleO::Services::HeatApi: puppet/services/heat-api.yaml
   OS::TripleO::Services::HeatApiCfn: puppet/services/heat-api-cfn.yaml
-  OS::TripleO::Services::HeatApiCloudwatch: puppet/services/heat-api-cloudwatch.yaml
+  OS::TripleO::Services::HeatApiCloudwatch: puppet/services/disabled/heat-api-cloudwatch-disabled.yaml
   OS::TripleO::Services::HeatEngine: puppet/services/heat-engine.yaml
   OS::TripleO::Services::Kernel: puppet/services/kernel.yaml
   OS::TripleO::Services::MySQL: puppet/services/database/mysql.yaml
similarity index 92%
rename from puppet/all-nodes-config.yaml
rename to puppet/all-nodes-config.j2.yaml
index 37c1d4e..bdd2bcf 100644 (file)
@@ -2,14 +2,10 @@ heat_template_version: pike
 description: 'All Nodes Config for Puppet'
 
 parameters:
-  cloud_name_external:
-    type: string
-  cloud_name_internal_api:
-    type: string
-  cloud_name_storage:
-    type: string
-  cloud_name_storage_mgmt:
+{%- for network in networks if network.vip|default(false) %}
+  cloud_name_{{network.name_lower}}:
     type: string
+{%- endfor %}
   cloud_name_ctlplane:
     type: string
   enabled_services:
@@ -70,30 +66,12 @@ parameters:
     type: boolean
     default: false
 
-  InternalApiNetName:
-    default: internal_api
-    description: The name of the internal_api network.
-    type: string
-  ExternalNetName:
-    default: external
-    description: The name of the external network.
-    type: string
-  ManagementNetName:
-    default: management
-    description: The name of the management network.
-    type: string
-  StorageNetName:
-    default: storage
-    description: The name of the storage network.
-    type: string
-  StorageMgmtNetName:
-    default: storage_mgmt
-    description: The name of the storage_mgmt network.
-    type: string
-  TenantNetName:
-    default: tenant
-    description: The name of the tenant network.
+{%- for network in networks %}
+  {{network.name}}NetName:
+    default: {{network.name_lower}}
+    description: The name of the {{network.name_lower}} network.
     type: string
+{%- endfor %}
 
 
 resources:
diff --git a/puppet/services/disabled/heat-api-cloudwatch-disabled.yaml b/puppet/services/disabled/heat-api-cloudwatch-disabled.yaml
new file mode 100644 (file)
index 0000000..f793571
--- /dev/null
@@ -0,0 +1,48 @@
+heat_template_version: pike
+
+description: >
+  Openstack Heat CloudWatch API service, disabled by default since Pike
+
+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
+
+outputs:
+  role_data:
+    description: Role data for the disabled Heat CloudWatch API
+    value:
+      service_name:  heat_api_cloudwatch_disabled
+      upgrade_tasks:
+        - name: Check if heat_api_cloudwatch is deployed
+          command: systemctl is-enabled openstack-heat-api-cloudwatch
+          tags: step1
+          ignore_errors: True
+          register: heat_api_cloudwatch_enabled
+        - name: Stop and disable heat_api_cloudwatch service (pre-upgrade not under httpd)
+          tags: step1
+          when: heat_api_cloudwatch_enabled.rc == 0
+          service: name=openstack-heat-api-cloudwatch state=stopped enabled=no
diff --git a/releasenotes/notes/disable-heat-api-cloudwatch-d5a471da22472bde.yaml b/releasenotes/notes/disable-heat-api-cloudwatch-d5a471da22472bde.yaml
new file mode 100644 (file)
index 0000000..5c732c0
--- /dev/null
@@ -0,0 +1,15 @@
+---
+upgrade:
+  - |
+    The Heat API Cloudwatch API is deprecated in Pike and so it removed
+    by default during the Ocata to Pike upgrade. If you wish to keep this
+    service then you should use the environments/heat-api-cloudwatch.yaml
+    environment file in the tripleo-heat-templates during the upgrade (note
+    that this is migrated to running under httpd, if you do decide to keep
+    this service on Pike).
+deprecations:
+  - |
+    The Heat API Cloudwatch API is deprecated in Pike and so it is now not
+    deployed by default. You can override this behaviour with the
+    environments/heat-api-cloudwatch.yaml environment file in the
+    tripleo-heat-templates.