@@ -3772,3 +3772,37 @@ def update_environment_ingress(cmd, environment, resource_group_name, workload_p
37723772
37733773 except Exception as e :
37743774 handle_raw_exception (e )
3775+
3776+ def reset_environment_ingress_to_defaults (cmd , environment , resource_group_name , workload_profile_name , no_wait = False ):
3777+ """Reset environment ingress configuration to default values.
3778+
3779+ :param cmd: Command context
3780+ :param environment: Name of the Container App environment
3781+ :param resource_group_name: Name of resource group
3782+ :param no_wait: Do not wait for the long-running operation to finish
3783+ :return: The updated ingress configuration
3784+ """
3785+ _validate_subscription_registered (cmd , CONTAINER_APPS_RP )
3786+
3787+ # Default values for environment ingress
3788+ default_min_replicas = 2
3789+ default_max_replicas = 10
3790+ default_termination_grace_period = 8
3791+ default_request_idle_timeout = 4
3792+ default_header_count_limit = 100
3793+
3794+ logger .warning ("Resetting environment ingress configuration to default values" )
3795+
3796+ # Call existing update method with default values
3797+ return update_environment_ingress (
3798+ cmd = cmd ,
3799+ environment = environment ,
3800+ resource_group_name = resource_group_name ,
3801+ workload_profile_name = workload_profile_name ,
3802+ min_replicas = default_min_replicas ,
3803+ max_replicas = default_max_replicas ,
3804+ termination_grace_period = default_termination_grace_period ,
3805+ request_idle_timeout = default_request_idle_timeout ,
3806+ header_count_limit = default_header_count_limit ,
3807+ no_wait = no_wait
3808+ )
0 commit comments