diff --git a/src/spring/azext_spring/_log_stream.py b/src/spring/azext_spring/_log_stream.py index 7d5c43ed84d..fb70adb5327 100644 --- a/src/spring/azext_spring/_log_stream.py +++ b/src/spring/azext_spring/_log_stream.py @@ -3,14 +3,11 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- -import re - class LogStream: def __init__(self, client, resource_group, service): test_keys = client.services.list_test_keys(resource_group, service) self.primary_key = test_keys.primary_key - # https://primary:xxxx[key]@servicename.test.azuremicrosoervice.io -> servicename.azuremicroservice.io - test_url = test_keys.primary_test_endpoint - base_url = test_url.replace('.test.', '.') - self.base_url = re.sub('https://.+?\@', '', base_url) + + resource = client.services.get(resource_group, service) + self.base_url = resource.properties.fqdn