Skip to content
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
get_three_state_flag, get_enum_type, tags_type)
from azure.cli.core.local_context import LocalContextAttribute, LocalContextAction
from azure.cli.command_modules.appservice._appservice_utils import MSI_LOCAL_ID
from azure.mgmt.web.models import DatabaseType, ConnectionStringType, BuiltInAuthenticationProvider, AzureStorageType
from azure.mgmt.web.models import (DatabaseType, ConnectionStringType, BuiltInAuthenticationProvider,
AzureStorageType, AutoGeneratedDomainNameLabelScope)

from ._completers import get_hostname_completion_list
from ._constants import (FUNCTIONS_VERSIONS, LOGICAPPS_NODE_RUNTIME_VERSIONS, WINDOWS_OS_NAME, LINUX_OS_NAME,
Expand Down Expand Up @@ -166,6 +167,7 @@ def load_arguments(self, _):
c.argument('acr_identity', help='Accept system or user assigned identity which will be set for acr image pull. '
'Use \'[system]\' to refer system assigned identity, or a resource id to refer user assigned identity.')
c.argument('basic_auth', help='Enable or disable basic auth for both SCM and FTP Basic Auth Publishing Credentials. Defaults to Enabled if not specified. See https://aka.ms/app-service-basic-auth to learn more.', arg_type=get_enum_type(BASIC_AUTH_TYPES))
c.argument('auto_generated_domain_name_label_scope', options_list=['--domain-name-scope'], help="Specify the scope of uniqueness for the default hostname during resource creation.", arg_type=get_enum_type(AutoGeneratedDomainNameLabelScope))
c.ignore('language')
c.ignore('using_webapp_up')

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,8 @@ def create_webapp(cmd, resource_group_name, name, plan, runtime=None, startup_fi
multicontainer_config_type=None, multicontainer_config_file=None, tags=None,
using_webapp_up=False, language=None, assign_identities=None,
role='Contributor', scope=None, vnet=None, subnet=None, https_only=False,
public_network_access=None, acr_use_identity=False, acr_identity=None, basic_auth=""):
public_network_access=None, acr_use_identity=False, acr_identity=None, basic_auth="",
auto_generated_domain_name_label_scope=None):
from azure.mgmt.web.models import Site
from azure.core.exceptions import ResourceNotFoundError as _ResourceNotFoundError
SiteConfig, SkuDescription, NameValuePair = cmd.get_models(
Expand Down Expand Up @@ -221,7 +222,8 @@ def create_webapp(cmd, resource_group_name, name, plan, runtime=None, startup_fi

webapp_def = Site(location=location, site_config=site_config, server_farm_id=plan_info.id, tags=tags,
https_only=https_only, virtual_network_subnet_id=subnet_resource_id,
public_network_access=public_network_access, vnet_route_all_enabled=vnet_route_all_enabled)
public_network_access=public_network_access, vnet_route_all_enabled=vnet_route_all_enabled,
auto_generated_domain_name_label_scope=auto_generated_domain_name_label_scope)
if runtime:
runtime = _StackRuntimeHelper.remove_delimiters(runtime)

Expand Down
Loading
Loading