fence-agents/bz2211460-fence_azure-arm-2-metadata-endpoint-error-message.patch

18 lines
756 B
Diff
Raw Normal View History

--- a/lib/azure_fence.py.py 2023-06-20 16:16:38.525301510 +0200
+++ b/lib/azure_fence.py.py 2023-06-20 16:15:52.336508620 +0200
@@ -317,12 +317,11 @@
from azure.mgmt.compute import ComputeManagementClient
cloud_environment = get_azure_cloud_environment(config)
+ if (config.Cloud.lower() == "stack") and not config.MetadataEndpoint:
+ fail_usage("metadata-endpoint not specified")
credentials = get_azure_credentials(config)
if cloud_environment:
- if (config.Cloud.lower() == "stack") and not config.MetadataEndpoint:
- fail_usage("metadata-endpoint not specified")
-
compute_client = ComputeManagementClient(
credentials,
config.SubscriptionId,