Skip to content

Commit 323c075

Browse files
committed
Merge remote-tracking branch 'upstream/main'
2 parents 1999e1b + e7519a9 commit 323c075

File tree

15 files changed

+3936
-3674
lines changed

15 files changed

+3936
-3674
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@
240240

241241
/src/quota/ @kairu-ms @ZengTaoxu
242242

243-
/src/containerapp/ @ruslany @sanchitmehta @ebencarek @JennyLawrance @howang-ms @vinisoto @chinadragon0515 @vturecek @torosent @pagariyaalok @Juliehzl @jijohn14
243+
/src/containerapp/ @ruslany @sanchitmehta @ebencarek @JennyLawrance @howang-ms @vinisoto @chinadragon0515 @vturecek @torosent @pagariyaalok @Juliehzl @jijohn14 @Greedygre @ShichaoQiu @bowen5
244244

245245
/src/scvmm/ @nascarsayan @hsurana06
246246

scripts/ci/avail-ext-doc/update_extension_list.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,16 @@ def get_extensions():
4242
exts = sorted(exts, key=lambda c: parse_version(c['metadata']['version']), reverse=True)
4343

4444
# some extension modules may not include 'HISTORY.rst'
45-
project_url = exts[0]['metadata']['extensions']['python.details']['project_urls']['Home']
45+
# setup.py
46+
if 'project_urls' in exts[0]['metadata']['extensions']['python.details']:
47+
project_url = exts[0]['metadata']['extensions']['python.details']['project_urls']['Home']
48+
# pyproject.toml
49+
elif 'project_url' in exts[0]['metadata']:
50+
project_url = exts[0]['metadata']['project_url'].replace('homepage,', '').strip()
51+
print(f"Warning: extension {exts[0]['metadata']['name']} has migrated to pyproject.toml.")
52+
else:
53+
project_url = ''
54+
print(f"Warning: No project_url found for extension {exts[0]['metadata']['name']}")
4655
history_tmp = project_url + '/HISTORY.rst'
4756
history = project_url if str(requests.get(history_tmp).status_code) == '404' else history_tmp
4857
if exts[0]['metadata'].get('azext.isPreview'):

src/confcom/HISTORY.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@
33
Release History
44
===============
55

6+
1.3.1
7+
++++++
8+
* bugfix for --exclude-default-fragments flag not working as intended
9+
610
1.3.0
711
++++++
812
* Add a new --enable-stdio flag, with a warning if neither this or --disable-stdio is set

src/confcom/azext_confcom/security_policy.py

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -675,13 +675,14 @@ def load_policy_from_arm_template_str(
675675
containers = []
676676
existing_containers = None
677677
fragments = None
678-
exclude_default_fragments = False
678+
group_exclude_default_fragments = exclude_default_fragments
679679

680680
tags = case_insensitive_dict_get(resource, config.ACI_FIELD_TEMPLATE_TAGS)
681681
if tags:
682-
exclude_default_fragments = case_insensitive_dict_get(tags, config.ACI_FIELD_TEMPLATE_ZERO_SIDECAR)
683-
if isinstance(exclude_default_fragments, str):
684-
exclude_default_fragments = exclude_default_fragments.lower() == "true"
682+
group_exclude_default_fragments = \
683+
case_insensitive_dict_get(tags, config.ACI_FIELD_TEMPLATE_ZERO_SIDECAR)
684+
if isinstance(group_exclude_default_fragments, str):
685+
group_exclude_default_fragments = group_exclude_default_fragments.lower() == "true"
685686

686687
container_group_properties = case_insensitive_dict_get(
687688
resource, config.ACI_FIELD_TEMPLATE_PROPERTIES
@@ -720,7 +721,10 @@ def load_policy_from_arm_template_str(
720721
else:
721722
existing_containers, fragments = ([], [])
722723

723-
rego_fragments = copy.deepcopy(config.DEFAULT_REGO_FRAGMENTS) if not exclude_default_fragments else []
724+
rego_fragments = (
725+
copy.deepcopy(config.DEFAULT_REGO_FRAGMENTS)
726+
if not group_exclude_default_fragments else []
727+
)
724728
if infrastructure_svn:
725729
# assumes the first DEFAULT_REGO_FRAGMENT is always the
726730
# infrastructure fragment

src/confcom/azext_confcom/tests/latest/test_confcom_acipolicygen_arm.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ def test_acipolicygen(sample_directory, generated_policy_path):
5454

5555
for failing_sample_directory, failing_generated_policy_paths in [
5656
("multi_container_groups", ("policy_fragment.rego", "policy_fragment_plus_infrastructure_svn.rego")), # TODO: https://github.com/Azure/azure-cli-extensions/issues/9229
57-
(None, ("policy_exclude_default_fragment.rego",)), # TODO: https://github.com/Azure/azure-cli-extensions/issues/9198
5857
]:
5958
if (
6059
(sample_directory == failing_sample_directory or failing_sample_directory is None)

src/containerapp/HISTORY.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ Release History
44
===============
55
upcoming
66
++++++
7+
* 'az containerapp env premium-ingress add/update': remove `--min-replicas` and `--max-replicas`
78

89
1.2.0b4
910
++++++

src/containerapp/azext_containerapp/_params.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -531,8 +531,6 @@ def load_arguments(self, _):
531531
c.argument('resource_group_name', arg_type=resource_group_name_type, id_part=None)
532532
c.argument('name', options_list=['--name', '-n'], help="The name of the managed environment.")
533533
c.argument('workload_profile_name', options_list=['--workload-profile-name', '-w'], help="The workload profile to run ingress replicas on. This profile must not be shared with any container app or job.")
534-
c.argument('min_replicas', options_list=['--min-replicas'], type=int, deprecate_info=c.deprecate(hide=True, expiration='2.79.0'), help="The workload profile minimum instances is used instead.")
535-
c.argument('max_replicas', options_list=['--max-replicas'], type=int, deprecate_info=c.deprecate(hide=True, expiration='2.79.0'), help="The workload profile maximum instances is used instead.")
536534
c.argument('termination_grace_period', options_list=['--termination-grace-period', '-t'], type=int, help="Time in seconds to drain requests during ingress shutdown. Default 500, minimum 0, maximum 3600.")
537535
c.argument('request_idle_timeout', options_list=['--request-idle-timeout'], type=int, help="Timeout in minutes for idle requests. Default 4, minimum 4, maximum 30.")
538536
c.argument('header_count_limit', options_list=['--header-count-limit'], type=int, help="Limit of http headers per request. Default 100, minimum 1.")

src/containerapp/azext_containerapp/custom.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3873,7 +3873,7 @@ def show_environment_premium_ingress(cmd, name, resource_group_name):
38733873
handle_raw_exception(e)
38743874

38753875

3876-
def add_environment_premium_ingress(cmd, name, resource_group_name, workload_profile_name, min_replicas=None, max_replicas=None, termination_grace_period=None, request_idle_timeout=None, header_count_limit=None, no_wait=False):
3876+
def add_environment_premium_ingress(cmd, name, resource_group_name, workload_profile_name, termination_grace_period=None, request_idle_timeout=None, header_count_limit=None, no_wait=False):
38773877
_validate_subscription_registered(cmd, CONTAINER_APPS_RP)
38783878

38793879
try:
@@ -3903,7 +3903,7 @@ def add_environment_premium_ingress(cmd, name, resource_group_name, workload_pro
39033903
handle_raw_exception(e)
39043904

39053905

3906-
def update_environment_premium_ingress(cmd, name, resource_group_name, workload_profile_name=None, min_replicas=None, max_replicas=None, termination_grace_period=None, request_idle_timeout=None, header_count_limit=None, no_wait=False):
3906+
def update_environment_premium_ingress(cmd, name, resource_group_name, workload_profile_name=None, termination_grace_period=None, request_idle_timeout=None, header_count_limit=None, no_wait=False):
39073907
_validate_subscription_registered(cmd, CONTAINER_APPS_RP)
39083908

39093909
try:

0 commit comments

Comments
 (0)