Remove hostname-format option

This option has not been used since at least the migratio to the
statemachine framework.

Change-Id: I7a0e928889f72606fcbba0c94c2d49fbb3ffe55f
This commit is contained in:
James E. Blair 2024-02-08 09:40:41 -08:00
parent f89b41f6ad
commit e097731339
4 changed files with 7 additions and 15 deletions

View File

@ -45,7 +45,6 @@ Selecting the OpenStack driver adds the following options to the
launch-timeout: 900
launch-retries: 3
image-name-format: '{image_name}-{timestamp}'
hostname-format: '{label.name}-{provider.name}-{node.id}'
post-upload-hook: /usr/bin/custom-hook
diskimages:
- name: trusty
@ -80,7 +79,6 @@ Selecting the OpenStack driver adds the following options to the
region-name: 'region1'
rate: 1.0
image-name-format: '{image_name}-{timestamp}'
hostname-format: '{label.name}-{provider.name}-{node.id}'
diskimages:
- name: precise
meta:
@ -156,12 +154,6 @@ Selecting the OpenStack driver adds the following options to the
The region name if the provider cloud has multiple regions.
.. attr:: hostname-format
:type: string
:default: {label.name}-{provider.name}-{node.id}
Hostname template to use for the spawned instance.
.. attr:: image-name-format
:type: string
:default: {image_name}-{timestamp}

View File

@ -344,7 +344,6 @@ class AwsProviderConfig(ProviderConfig):
'profile-name': str,
'cloud-images': [provider_cloud_images],
'diskimages': [provider_diskimages],
'hostname-format': str,
'boot-timeout': int,
'launch-timeout': int,
'launch-retries': int,

View File

@ -176,7 +176,6 @@ class OpenStackProviderConfig(ProviderConfig):
self.port_cleanup_interval = None
self.diskimages = {}
self.cloud_images = {}
self.hostname_format = None
self.image_name_format = None
self.post_upload_hook = None
super().__init__(provider)
@ -214,10 +213,6 @@ class OpenStackProviderConfig(ProviderConfig):
'port-cleanup-interval',
600
)
self.hostname_format = self.provider.get(
'hostname-format',
'{label.name}-{provider.name}-{node.id}'
)
self.image_name_format = self.provider.get(
'image-name-format',
'{image_name}-{timestamp}'
@ -348,7 +343,6 @@ class OpenStackProviderConfig(ProviderConfig):
'launch-retries': int,
'nodepool-id': str,
'rate': v.Coerce(float),
'hostname-format': str,
'image-name-format': str,
'clean-floating-ips': bool,
'port-cleanup-interval': int,

View File

@ -0,0 +1,7 @@
---
upgrade:
- |
The hostname-format option, previously available for the OpenStack
and AWS drivers, but unused for some time, has been removed.
Remove any uses of it from nodepool config files before upgrading;
otherwise they will fail config validation.