Skip to content

Commit 7899ccf

Browse files
[confcom] Rollback genpolicy version to Azure Linux V2 (#8725)
* filter genpolicy releases (#94) * When downloading a genpolicy release, filter the list of releases to only include those that are not marked as "prerelease" or "draft" Signed-off-by: Saul Paredes <saulparedes@microsoft.com> * updating history * updating styling * fixing layers --------- Signed-off-by: Saul Paredes <saulparedes@microsoft.com> Co-authored-by: Saul Paredes <30801614+Redent0r@users.noreply.github.com>
1 parent ea3971a commit 7899ccf

File tree

5 files changed

+14
-5
lines changed

5 files changed

+14
-5
lines changed

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.2.4
7+
++++++
8+
* rolling back genpolicy version for Azure Linux V2 support instead of V3
9+
610
1.2.3
711
++++++
812
* adding fragment support for VN2

src/confcom/azext_confcom/data/internal_config.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "1.2.3",
2+
"version": "1.2.4",
33
"hcsshim_config": {
44
"maxVersion": "1.0.0",
55
"minVersion": "0.0.1"

src/confcom/azext_confcom/kata_proxy.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,12 @@ def download_binaries():
4040
needed_assets = ["genpolicy", "genpolicy.exe"]
4141
# search for genpolicy in the assets from kata-container releases
4242
for release in r.json():
43-
if "genpolicy" in release.get("tag_name"):
43+
is_target = (
44+
"genpolicy" in release.get("tag_name") and
45+
not release.get("draft") and
46+
not release.get("prerelease")
47+
)
48+
if is_target:
4449
# these should be newest to oldest
4550
for asset in release["assets"]:
4651
# download the file if it contains genpolicy

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -577,8 +577,8 @@ def test_image_layers_python(self):
577577
aci_policy.populate_policy_content_for_all_images()
578578
layers = aci_policy.get_images()[0]._layers
579579
expected_layers = [
580-
"f4dbab29a5ddebfa8866d72df10d284ffb2b11292baf8d184b7bc1241d5074fd",
581-
"c003cd912b804162760beb676e5b629a297d75fbdcffd2d3ee49bacc0b985a52"
580+
"81f4183d118e68e8bb3c8845da3b0fe3cc331a63184b534ea0307d4d01c52418",
581+
"3a1edaedd7e7e0072846d74219577c05b25498c233196d38ae0fe6cde8c2c92a"
582582
]
583583
self.assertEqual(len(layers), len(expected_layers))
584584
for i in range(len(expected_layers)):

src/confcom/setup.py

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

2020
logger.warn("Wheel is not available, disabling bdist_wheel hook")
2121

22-
VERSION = "1.2.3"
22+
VERSION = "1.2.4"
2323

2424
# The full list of classifiers is available at
2525
# https://pypi.python.org/pypi?%3Aaction=list_classifiers

0 commit comments

Comments
 (0)