app-admin/salt: bump to v3007.2
This commit is contained in:
parent
065c7f9947
commit
66e4c264fe
@ -1,24 +1 @@
|
||||
AUX api-confd-1 179 BLAKE2B d014cadfb5dd99c85b1dee0e743f413fc5d6eb05629045bad5df108e6e96104b3b4f5e3736518baff5473c68d94906bb90cb7fe8167e136dd6603eb1087cc01c SHA512 de1d70050c2f911abb306c1b2253f2fdaac505a5ddd34937d7bef9dc9b876e9c6ed06e330a816fcafa38feaf67837235e78f2d97d149fef9fe20a29d945f8f22
|
||||
AUX api-initd-5 540 BLAKE2B 11a4d14aaff3040484e9e704f68cc7562fe52694f7dc5eb6df0ab6cbac0cc4c4958c1f9cf13402a5f4f1c4361c93c44e71228a2f8f7f69b1c400a280c8934659 SHA512 81a0e3b01d95af5475f6fd12614134ca84c9d53b68648aba9b328947d6e92fae1889276d58cb3749e3e542f42dbda507d28531102549b4fc6c109e2f14146f8b
|
||||
AUX master-confd-1 188 BLAKE2B 8ac416a7ff64c73556f07a08268ea7d91547e242becd345ac35da7b64f6b2e4aba276e8920e7353bd2caeaffa3034349496b00622191793994bbd4d25faa3c3c SHA512 c58fc025a3654b59f79c6e23fe135d75ebad8b166bc5214f4842c3dd92192e3598480f9fd6960ad2dc36d3ee45ff971650c5e0156353c1c045650f86c9a68db9
|
||||
AUX master-initd-5 558 BLAKE2B 09a1485449b239b4f0d7e0514572084769c73b28053fc6ff9b4cbeb239358e7311784c15e883ddf5ca8310794e3d2bb851f2a765bb3aa17f8081ee008bfd130a SHA512 36b2d601d4dd3bd7b1758e77029b70916adbf8919c3ef04fd867ca25b143666d0c2f5834adddf05e7c2b013f04939f57e3396c888514e08f1679e6459a6ce7bb
|
||||
AUX minion-confd-1 188 BLAKE2B ad20094c30f9aa573397d347f9fb11acafba2f724b6c836d7ec57f10d4182c300a4b0ec572b5f3301174febdfc69c30752c3b0eabdfdf9f4963b03531db23523 SHA512 0051e13351cef8db81dc075a194bb384723f07d5591b5b4d3f3adf4180afaf7beced470ab79ceca9d1ec0dae62dbd72084eb76af009fc78411a011050a94a2ed
|
||||
AUX minion-initd-5 564 BLAKE2B 19f2d909b1a91b5cf22c932b04b794ef536c3a84fbd36676d4bf136c6af66ae4ea94abcf9657919cb4cf85ee88cc6e93df0e7373e0410823550cc45ebc8f5673 SHA512 c92165fe73157c9c3898f7c8c90e3b1626f704d4a8432237bd264463c66ba00e89a1d66e44b049703fd32ce48f771248b902e7183c4e31ee6611f938704b2583
|
||||
AUX salt-3002-tests.patch 1125 BLAKE2B 345c094c38a1b62190587062a86da4e0a516988fb2bbf98c295da87f0abd456cfc8f25c11fe10a1c4571d4eb25390c6d89b0e300bd2ae6d82212d1685af8ed30 SHA512 7f9d6f8c4a5d34381c516c72d77de6613ed646fb88f89b7c4180afebb0bf0ee34a99ed02a7e8d7a6836a61c01653fe97a13c8caa18898a507a03091cff8e9d30
|
||||
AUX salt-3003-gentoolkit-revdep.patch 514 BLAKE2B aff27558a2043970feeb3eda70cf8e9112b5545af40ba215c7859520ef95a9824001274e837929ef6c25f8e1c35a8ac73f1033e63336bcbaf48dbd4b54c2d42c SHA512 c8a4649ac241f219cf576b0896f48dffc0d5a273118713829c0ad34594f77cffceaa4f06a4d0f47a17b13d6e71b5787fc27f8ee97c774e53a6d15d1b282f99b3
|
||||
AUX salt-3003-skip-tests-that-oom-machine.patch 732 BLAKE2B b9e10cf8d9ce7f36371fd30fcf592dce4933a05ca2d85c41b2159233272f2e7c90315fbd998c4064f3733b5b1944f9f96816418ed7eb434f3b9df324de2e859b SHA512 e7bc9c63d95a9af4e85372ca973c5023660c332b67486382ce898e7d60c3f50e2aca59e2634a2e87ab7fa8b34e45bfd3a781e04b8003108efbfcc67cd921aff4
|
||||
AUX salt-3003.1-tests.patch 1151 BLAKE2B b2f0d99bf4bd90a7ea85ae5cc6abb91dd078ad8a95b062863a21573067f3df6045fe23ffd1b3f397e28b90b25126798253e8a9001509ad786cee3f318a900321 SHA512 9340a1dd343af45467be63b1f6991cd06fa57ffc187bcff4a96c75a9666a1429b98ce5b497354bc4cb975c0f6bcd9a64dbfb819b6bfdba02bb5917446d0a36fc
|
||||
AUX salt-3005-relax-pyzmq-dep.patch 332 BLAKE2B d22d94b7680fb81e642b83cb7d823137e7e208b43a1720b131401fb957bcb3deb6a0fe5ca87da528cdf60ac219820d259d0b03a905e17142c9cd4d939b4bacf1 SHA512 7c5b963436c3066bf8e8f528acf04ea8ddfa2a5a19adb9486f9888346d55e56fdfcd97a4a04db18d85476cb8ecc8a350343855d765387744706e43e868464f5e
|
||||
AUX salt-3005-tests.patch 4101 BLAKE2B 6a7d7dee4e631a7619bf1b7fa6bd08b93c0bf31342ce72f734bb645206604ffed9ae2ddae9cebe01401cbe100c224e97f18a69ede5f40a041158d1cd8878dc0f SHA512 cbc3b3d625ab8e20aa7b166dd6ddca1728c4bf562cc14d28fa684573c6ee1d42a270b0f029e5d978803a30103e7ad281d516afff66d18bf31308528fae79c00c
|
||||
AUX salt-3005.1-importlib-metadata-5-r1.patch 1162 BLAKE2B cbc8df0043881725eb00a6e45ccc03e25f95a6260b4a4b42343c69a6bd8edcf0bb45312644a8e6a66b50a0c4ce0aad7be454b1b8d54a786851b33c7d4b143e10 SHA512 7d2f8c86f22b238dabda0727c338e2e8d33e06a36fcccf5b3b508ac610899f2d6416d7c9e285e992f0d76fc9d04c126640b2b84a227f9a82f4973cb472a4a14a
|
||||
AUX salt-3005.1-modules-file-python-3.11-host.patch 4206 BLAKE2B 9cd3cb68b5c1a95475834ae917a2f6fbdbe3424c9f1e837a0e797b84e291e3530f86a2f7d2286e0070f433817ec06b2fd4d0a069b47acb1b0646653862337ece SHA512 4bc03979e1a4202d5ccb2b3159e178bc72c2a4be4297d7b9306479a5c7fe8cc81fc7d25474d80c2627e638db25e73cd4e8f7e1b25c8e15317e22986d63307823
|
||||
AUX salt-3005.1-no-entry-points.patch 428 BLAKE2B 1bcf3b070afd01c56985290051a3cb031d5ca83b42631eba5f05d7648eabf13bca44573811b767d739dc9bc6d0a5da6f99de87b57c678df79cc172fa6dd5495f SHA512 ed5712689a6d39da9c6a67f28a48d35bbd271a6a3b898cbb0e0493e1813cc99e64388fb60707e6fee95691e339336c2656278780115b39d285c380ded92fe3cb
|
||||
AUX salt-3005.1-tests.patch 2367 BLAKE2B 467af423de22b4ddeb80fef3d4682976283116698b7c2551c4710e049d8ad7749a4eb07c541a427ed540fdea6a0e4f4e63d96988bafd92974cc3b1026e27fd03 SHA512 4ba3c36be9de377848880819fc4bacf72978a12e483bea90a4e5e7524d7212b5d554302000f6c628156ec5aafbf48d662dec2764d96253be74fa202c73e7fc67
|
||||
AUX salt-api.service 166 BLAKE2B 32d28ef4ef3c60942bed3fa3a01d70a9af387705844326cdf9339d7c887238a1e6817d78ffd1cb205a6397a2138c2389ea00bf53be84a17b23bea140279bf42c SHA512 bab6b8380c965bf16e23078ebe6f38d942300829d4c89ddf23b630bd57b4d371f80687d85dd9e0cc1b669f2ca882aecde1bc8d7d82382a02ed20e493d3f04702
|
||||
AUX salt-master.service 169 BLAKE2B 15e7a4f64cfa75eb8d8576a7d0b61ea0c9937c94fd2130fd6c123a82187f08b5ed533c168a7310fd94d9bd2cecf9d0ba94665c653a971ef61e5e18ffdf087a15 SHA512 87fe27fc0748f4191bd1c6883bb362c95cce8fe1f409e2679b229ddfd9de6c99438859dfa0a47b042977d659029ef56e406f1e8aa01761bff21af4784f9dd5f8
|
||||
AUX salt-minion.service 162 BLAKE2B 6f7b6b72e26d1651dbcb324b1e0cfef9f4b5a794f40566297c5bc469b351587db4d9805bed124774107efb64e6ed3e25fefa899b42a38064ee6fe26fd990ae58 SHA512 99f0a5c696e38b42b283416736a23e535ccc53095928b205914cf4b69c0df931a6752205985726527f7889b01dfece78466be28448458b15064edd04aca3e5ed
|
||||
AUX salt-syndic.service 169 BLAKE2B 0d00f20b4663804eaa4b6a1a1b32ed87b04d1f4df6a8e8e0b2a0e3d17f71e1bb53f71f6168446aaf3765692cd540217c4cdf5ab8dd9cb7032801aa798d8a9bc3 SHA512 b45509a22a18f573726a868fda1591eaf42ef44220960dda698274ba8ff1db8cdc302605133ab61b188e15017ba15c5f409f3ee64e026b635ac359eea7aad7d0
|
||||
AUX syndic-confd-1 188 BLAKE2B 98f13eb627963d65df26140f348c04eb8c253d444d36ecd1f5ef344ad89901b0a5ed62c64364e90595c2d2ee2766f30802a4a86a2555bbea343ab410292359af SHA512 35fe9bf4732c8a53b47099ffe5f9468d884ec3e2671451a6d52821dde6c70c63176b29ade0d700b99aaf47557f58179f780422843346bd3aa6513d9465ec9f58
|
||||
AUX syndic-initd-5 558 BLAKE2B 5e1ea25b57f56ad7bfb8be0c845e7da9f99af03c50c31ca2031e604267c680555d0d8a3ef6299ec588770f26dad19d262c8b9403391b60fb17c6811d7946107a SHA512 6e927925cf1e4d0f901bec10499a8ecf1193b99742cfda5f94f70d0ec743902b1b89728cb2e447b8b4879a9417d0d482b813161968dc9c2b2c7944b3af14df14
|
||||
DIST salt-3005.1.tar.gz 17914349 BLAKE2B 697c2068bf119e4a19f92a86ce880fec9375c10ba549cdcdd2182cfeaacce31c7bc4c4c91e1a609906b4c5373bb5e3120e0db47ede5b45ee20942d7b2d201e64 SHA512 391f995f0129f3d7104a0eea4fd83b18aa6ecae0fd7a2c77c1154e24b0bcd52cef4b63db12597c85737bb33ddf605e0c23370cef3bf47f9ea85af5b77d74dc50
|
||||
EBUILD salt-3005.1-r1.ebuild 7226 BLAKE2B 46a302e03d89dd596ed4e617b8ff37b934669f4569c5bd431c7b8cbbf6cf7defd1839ebcbbb6376e3542899b93e87350427cd2336ab88ca70a6af60bf415fdb6 SHA512 762b081b18ff10c44bb7a6f0aec52e121da322838ef485204e3b7f09a24fc68ffe9e9b7effa0b4b8298f289c99a1a5f8adcac1b85840bb561e3e1d52ac29c466
|
||||
DIST salt-3007.2.tar.gz 19475765 BLAKE2B 2eb69fe90109e2fdf2b038e02c925fa85585895dc14d20b3575fcf0d50a9b46eb02f747243a2eeb24dd010619513335052387811ed801ace8c228b3a3943d8d6 SHA512 8ea51a80fe777f68b42c9917c91fe9dbd30a413bc84cc2ab744432bf0b98bcbed5a66970beff476d21d0a72b0b75b5e49f03441e492315828d6cb2509a6dd485
|
||||
|
||||
@ -1,27 +0,0 @@
|
||||
diff --git a/tests/unit/utils/test_verify.py b/tests/unit/utils/test_verify.py
|
||||
index 5662cf621b..16aa6d08da 100644
|
||||
--- a/tests/unit/utils/test_verify.py
|
||||
+++ b/tests/unit/utils/test_verify.py
|
||||
@@ -329,6 +329,7 @@ class TestVerifyLog(TestCase):
|
||||
self.assertTrue(os.path.exists(path))
|
||||
|
||||
|
||||
+@skipIf(True, "skipping since temp dir is a symlink")
|
||||
class TestCleanPath(TestCase):
|
||||
"""
|
||||
salt.utils.clean_path works as expected
|
||||
@@ -394,12 +395,14 @@ class TestCleanPathLink(TestCase):
|
||||
def tearDown(self):
|
||||
shutil.rmtree(self.tmpdir)
|
||||
|
||||
+ @skipIf(True, "skipping since temp dir is a symlink")
|
||||
def test_clean_path_symlinked_src(self):
|
||||
test_path = os.path.join(self.from_path, "test")
|
||||
expect_path = os.path.join(self.to_path, "test")
|
||||
ret = clean_path(self.from_path, test_path)
|
||||
assert ret == expect_path, "{} is not {}".format(ret, expect_path)
|
||||
|
||||
+ @skipIf(True, "skipping since temp dir is a symlink")
|
||||
def test_clean_path_symlinked_tgt(self):
|
||||
test_path = os.path.join(self.to_path, "test")
|
||||
expect_path = os.path.join(self.to_path, "test")
|
||||
@ -1,20 +0,0 @@
|
||||
diff --git a/tests/unit/modules/test_boto_apigateway.py b/tests/unit/modules/test_boto_apigateway.py
|
||||
index 6ee6aeb002..db9aeaee95 100644
|
||||
--- a/tests/unit/modules/test_boto_apigateway.py
|
||||
+++ b/tests/unit/modules/test_boto_apigateway.py
|
||||
@@ -154,6 +154,7 @@ def _has_required_botocore():
|
||||
return True
|
||||
|
||||
|
||||
+@skipIf(True, "Causes machines to OOM")
|
||||
class BotoApiGatewayTestCaseBase(TestCase, LoaderModuleMockMixin):
|
||||
conn = None
|
||||
|
||||
@@ -190,6 +191,7 @@ class BotoApiGatewayTestCaseBase(TestCase, LoaderModuleMockMixin):
|
||||
self.addCleanup(delattr, self, "utils")
|
||||
|
||||
|
||||
+@skipIf(True, "Causes machines to OOM")
|
||||
class BotoApiGatewayTestCaseMixin:
|
||||
def _diff_list_dicts(self, listdict1, listdict2, sortkey):
|
||||
"""
|
||||
@ -1,25 +0,0 @@
|
||||
diff --git a/tests/integration/files/file/base/_modules/runtests_helpers.py b/tests/integration/files/file/base/_modules/runtests_helpers.py
|
||||
index 3ee0e2da5f..abf9b71431 100644
|
||||
--- a/tests/integration/files/file/base/_modules/runtests_helpers.py
|
||||
+++ b/tests/integration/files/file/base/_modules/runtests_helpers.py
|
||||
@@ -27,7 +27,7 @@ except ImportError:
|
||||
else "/tmp"
|
||||
)
|
||||
# This tempdir path is defined on tests.integration.__init__
|
||||
- TMP = os.path.join(SYS_TMP_DIR, "salt-tests-tmpdir")
|
||||
+ TMP = os.path.join(SYS_TMP_DIR, "salt-t")
|
||||
|
||||
class RUNTIME_VARS:
|
||||
TMP = TMP
|
||||
diff --git a/tests/unit/ext/test_ipaddress.py b/tests/unit/ext/test_ipaddress.py
|
||||
index 4fd87d1c3f..43306ba8f4 100644
|
||||
--- a/tests/unit/ext/test_ipaddress.py
|
||||
+++ b/tests/unit/ext/test_ipaddress.py
|
||||
@@ -137,6 +137,7 @@ class CommonTestMixin:
|
||||
|
||||
|
||||
class CommonTestMixin_v4(CommonTestMixin):
|
||||
+ @pytest.mark.skipif(sys.hexversion >= 0x03090000, reason="leading zeros disallowed in 3.9+")
|
||||
def test_leading_zeros(self):
|
||||
self.assertInstancesEqual("000.000.000.000", "0.0.0.0")
|
||||
self.assertInstancesEqual("192.168.000.001", "192.168.0.1")
|
||||
@ -1,12 +0,0 @@
|
||||
diff --git a/requirements/zeromq.txt b/requirements/zeromq.txt
|
||||
index eb4d796418..ffa1589043 100644
|
||||
--- a/requirements/zeromq.txt
|
||||
+++ b/requirements/zeromq.txt
|
||||
@@ -1,6 +1,4 @@
|
||||
-r base.txt
|
||||
-r crypto.txt
|
||||
|
||||
-pyzmq<=20.0.0 ; python_version < "3.6"
|
||||
-pyzmq>=17.0.0 ; python_version < "3.9"
|
||||
-pyzmq>19.0.2 ; python_version >= "3.9"
|
||||
+pyzmq
|
||||
@ -1,94 +0,0 @@
|
||||
diff --git a/tests/conftest.py b/tests/conftest.py
|
||||
index 24ecf57e04..babc7ced90 100644
|
||||
--- a/tests/conftest.py
|
||||
+++ b/tests/conftest.py
|
||||
@@ -684,8 +684,6 @@ def salt_factories_config():
|
||||
"""
|
||||
return {
|
||||
"code_dir": str(CODE_DIR),
|
||||
- "inject_coverage": MAYBE_RUN_COVERAGE,
|
||||
- "inject_sitecustomize": MAYBE_RUN_COVERAGE,
|
||||
"start_timeout": 120
|
||||
if (os.environ.get("JENKINS_URL") or os.environ.get("CI"))
|
||||
else 60,
|
||||
diff --git a/tests/pytests/unit/_logging/handlers/test_deferred_stream_handler.py b/tests/pytests/unit/_logging/handlers/test_deferred_stream_handler.py
|
||||
index 230da8abc8..f6f1a70ce4 100644
|
||||
--- a/tests/pytests/unit/_logging/handlers/test_deferred_stream_handler.py
|
||||
+++ b/tests/pytests/unit/_logging/handlers/test_deferred_stream_handler.py
|
||||
@@ -62,6 +62,7 @@ def _deferred_write_on_flush_proc_target():
|
||||
assert stds.stderr == "Foo\nBar\n"
|
||||
|
||||
|
||||
+@pytest.mark.skip("doesn't work with sandbox")
|
||||
def test_sync_with_handlers():
|
||||
proc = multiprocessing.Process(target=_sync_with_handlers_proc_target)
|
||||
proc.start()
|
||||
@@ -69,6 +70,7 @@ def test_sync_with_handlers():
|
||||
assert proc.exitcode == 0
|
||||
|
||||
|
||||
+@pytest.mark.skip("doesn't work with sandbox")
|
||||
def test_deferred_write_on_flush():
|
||||
proc = multiprocessing.Process(target=_deferred_write_on_flush_proc_target)
|
||||
proc.start()
|
||||
diff --git a/tests/pytests/unit/modules/test_portage_config.py b/tests/pytests/unit/modules/test_portage_config.py
|
||||
index 5cc6b90596..f344526909 100644
|
||||
--- a/tests/pytests/unit/modules/test_portage_config.py
|
||||
+++ b/tests/pytests/unit/modules/test_portage_config.py
|
||||
@@ -53,7 +53,7 @@ def test_enforce_nice_config(tmp_path):
|
||||
("use", ["apple", "-banana", "ananas", "orange"]),
|
||||
]
|
||||
|
||||
- base_path = str(tmp_path / "/package.{0}")
|
||||
+ base_path = str(f"{tmp_path}/package.{{0}}")
|
||||
|
||||
def make_line(atom, addition):
|
||||
return atom + (" " + addition if addition != "" else "") + "\n"
|
||||
@@ -72,14 +72,3 @@ def test_enforce_nice_config(tmp_path):
|
||||
portage_config, "_merge_flags", lambda l1, l2, _: list(set(l1 + l2))
|
||||
):
|
||||
portage_config.enforce_nice_config()
|
||||
-
|
||||
- for typ, additions in supported:
|
||||
- for atom, file_name in atoms:
|
||||
- with salt.utils.files.fopen(
|
||||
- base_path.format(typ) + "/" + file_name, "r"
|
||||
- ) as fh:
|
||||
- for line in fh:
|
||||
- for atom in line:
|
||||
- assert atom not in line
|
||||
- for addition in additions:
|
||||
- assert addition not in line
|
||||
diff --git a/tests/support/cli_scripts.py b/tests/support/cli_scripts.py
|
||||
index 270af75d4b..50c08f4ed2 100644
|
||||
--- a/tests/support/cli_scripts.py
|
||||
+++ b/tests/support/cli_scripts.py
|
||||
@@ -32,8 +32,6 @@ def get_script_path(bin_dir, script_name):
|
||||
bin_dir=bin_dir,
|
||||
script_name=script_name,
|
||||
code_dir=RUNTIME_VARS.CODE_DIR,
|
||||
- inject_coverage="COVERAGE_PROCESS_START" in os.environ,
|
||||
- inject_sitecustomize="COVERAGE_PROCESS_START" in os.environ,
|
||||
)
|
||||
log.info("Returning script path %r", script_path)
|
||||
return script_path
|
||||
diff --git a/tests/unit/utils/test_schema.py b/tests/unit/utils/test_schema.py
|
||||
index 8c648f5288..ce5715a562 100644
|
||||
--- a/tests/unit/utils/test_schema.py
|
||||
+++ b/tests/unit/utils/test_schema.py
|
||||
@@ -873,6 +873,7 @@ class ConfigTestCase(TestCase):
|
||||
)
|
||||
|
||||
@skipIf(HAS_JSONSCHEMA is False, "The 'jsonschema' library is missing")
|
||||
+ @skipIf(True, "Does not work with sandbox")
|
||||
def test_hostname_config_validation(self):
|
||||
class TestConf(schema.Schema):
|
||||
item = schema.HostnameItem(title="Item", description="Item description")
|
||||
@@ -2099,6 +2100,7 @@ class ConfigTestCase(TestCase):
|
||||
self.assertEqual(item.serialize(), {"not": item.item.serialize()})
|
||||
|
||||
@skipIf(HAS_JSONSCHEMA is False, "The 'jsonschema' library is missing")
|
||||
+ @skipIf(True, "Does not work with sandbox")
|
||||
def test_not_config_validation(self):
|
||||
class TestConf(schema.Schema):
|
||||
item = schema.ArrayItem(
|
||||
@ -1,29 +0,0 @@
|
||||
diff --git a/salt/utils/entrypoints.py b/salt/utils/entrypoints.py
|
||||
index 3effa0b494..9452878ade 100644
|
||||
--- a/salt/utils/entrypoints.py
|
||||
+++ b/salt/utils/entrypoints.py
|
||||
@@ -38,13 +38,20 @@ def iter_entry_points(group, name=None):
|
||||
entry_points_listing = []
|
||||
entry_points = importlib_metadata.entry_points()
|
||||
|
||||
- for entry_point_group, entry_points_list in entry_points.items():
|
||||
- if entry_point_group != group:
|
||||
- continue
|
||||
- for entry_point in entry_points_list:
|
||||
+ try:
|
||||
+ for entry_point in entry_points.select(group=group):
|
||||
if name is not None and entry_point.name != name:
|
||||
continue
|
||||
entry_points_listing.append(entry_point)
|
||||
+ except AttributeError:
|
||||
+ # importlib-metadata<5.0.0
|
||||
+ for entry_point_group, entry_points_list in entry_points.items():
|
||||
+ if entry_point_group != group:
|
||||
+ continue
|
||||
+ for entry_point in entry_points_list:
|
||||
+ if name is not None and entry_point.name != name:
|
||||
+ continue
|
||||
+ entry_points_listing.append(entry_point)
|
||||
|
||||
return entry_points_listing
|
||||
|
||||
@ -1,123 +0,0 @@
|
||||
diff --git a/salt/modules/file.py b/salt/modules/file.py
|
||||
index f39d618203..93eeaf312e 100644
|
||||
--- a/salt/modules/file.py
|
||||
+++ b/salt/modules/file.py
|
||||
@@ -16,7 +16,6 @@ import hashlib
|
||||
import itertools
|
||||
import logging
|
||||
import mmap
|
||||
-import operator
|
||||
import os
|
||||
import re
|
||||
import shutil
|
||||
@@ -28,7 +27,6 @@ import time
|
||||
import urllib.parse
|
||||
from collections import namedtuple
|
||||
from collections.abc import Iterable, Mapping
|
||||
-from functools import reduce
|
||||
|
||||
import salt.utils.args
|
||||
import salt.utils.atomicfile
|
||||
@@ -1622,38 +1620,38 @@ def comment_line(path, regex, char="#", cmnt=True, backup=".bak"):
|
||||
|
||||
def _get_flags(flags):
|
||||
"""
|
||||
- Return an integer appropriate for use as a flag for the re module from a
|
||||
- list of human-readable strings
|
||||
+ Return the names of the Regex flags that correspond to flags
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
- >>> _get_flags(['MULTILINE', 'IGNORECASE'])
|
||||
- 10
|
||||
+ >>> _get_flags(['IGNORECASE', 'MULTILINE'])
|
||||
+ re.IGNORECASE|re.MULTILINE
|
||||
>>> _get_flags('MULTILINE')
|
||||
- 8
|
||||
- >>> _get_flags(2)
|
||||
- 2
|
||||
+ re.MULTILINE
|
||||
+ >>> _get_flags(8)
|
||||
+ re.MULTILINE
|
||||
+ >>> _get_flags(re.IGNORECASE)
|
||||
+ re.IGNORECASE
|
||||
"""
|
||||
- if isinstance(flags, str):
|
||||
+ if isinstance(flags, re.RegexFlag):
|
||||
+ return flags
|
||||
+ elif isinstance(flags, int):
|
||||
+ return re.RegexFlag(flags)
|
||||
+ elif isinstance(flags, str):
|
||||
flags = [flags]
|
||||
|
||||
if isinstance(flags, Iterable) and not isinstance(flags, Mapping):
|
||||
- _flags_acc = [0] # An initial 0 avoids resucing on empty list, an error
|
||||
+ _flags = re.RegexFlag(0)
|
||||
for flag in flags:
|
||||
- _flag = getattr(re, str(flag).upper())
|
||||
-
|
||||
- if not isinstance(_flag, int):
|
||||
- raise SaltInvocationError("Invalid re flag given: {}".format(flag))
|
||||
-
|
||||
- _flags_acc.append(_flag)
|
||||
-
|
||||
- return reduce(operator.__or__, _flags_acc)
|
||||
- elif isinstance(flags, int):
|
||||
- return flags
|
||||
+ _flag = getattr(re.RegexFlag, str(flag).upper(), None)
|
||||
+ if not _flag:
|
||||
+ raise CommandExecutionError(f"Invalid re flag given: {flag}")
|
||||
+ _flags |= _flag
|
||||
+ return _flags
|
||||
else:
|
||||
- raise SaltInvocationError(
|
||||
- 'Invalid re flags: "{}", must be given either as a single flag '
|
||||
- "string, a list of strings, or as an integer".format(flags)
|
||||
+ raise CommandExecutionError(
|
||||
+ f'Invalid re flags: "{flags}", must be given either as a single flag '
|
||||
+ "string, a list of strings, as an integer, or as an re flag"
|
||||
)
|
||||
|
||||
|
||||
@@ -2513,8 +2511,8 @@ def replace(
|
||||
"Only one of append and prepend_if_not_found is permitted"
|
||||
)
|
||||
|
||||
- flags_num = _get_flags(flags)
|
||||
- cpattern = re.compile(salt.utils.stringutils.to_bytes(pattern), flags_num)
|
||||
+ re_flags = _get_flags(flags)
|
||||
+ cpattern = re.compile(salt.utils.stringutils.to_bytes(pattern), re_flags)
|
||||
filesize = os.path.getsize(path)
|
||||
if bufsize == "file":
|
||||
bufsize = filesize
|
||||
@@ -2582,7 +2580,7 @@ def replace(
|
||||
"^{}($|(?=\r\n))".format(re.escape(content))
|
||||
),
|
||||
r_data,
|
||||
- flags=flags_num,
|
||||
+ flags=re_flags,
|
||||
):
|
||||
# Content was found, so set found.
|
||||
found = True
|
||||
@@ -3132,7 +3130,11 @@ def search(path, pattern, flags=8, bufsize=1, ignore_if_missing=False, multiline
|
||||
salt '*' file.search /etc/crontab 'mymaintenance.sh'
|
||||
"""
|
||||
if multiline:
|
||||
- flags = _add_flags(flags, "MULTILINE")
|
||||
+ re_flags = _add_flags(flags, "MULTILINE")
|
||||
+ else:
|
||||
+ re_flags = _get_flags(flags)
|
||||
+
|
||||
+ if re.RegexFlag.MULTILINE in re_flags:
|
||||
bufsize = "file"
|
||||
|
||||
# This function wraps file.replace on purpose in order to enforce
|
||||
@@ -3142,7 +3144,7 @@ def search(path, pattern, flags=8, bufsize=1, ignore_if_missing=False, multiline
|
||||
path,
|
||||
pattern,
|
||||
"",
|
||||
- flags=flags,
|
||||
+ flags=re_flags,
|
||||
bufsize=bufsize,
|
||||
dry_run=True,
|
||||
search_only=True,
|
||||
@ -1,13 +0,0 @@
|
||||
diff --git a/setup.py b/setup.py
|
||||
index bd11ff95f7..3b83f7b6ff 100755
|
||||
--- a/setup.py
|
||||
+++ b/setup.py
|
||||
@@ -1173,7 +1173,7 @@ class SaltDistribution(distutils.dist.Distribution):
|
||||
return scripts
|
||||
|
||||
@property
|
||||
- def _property_entry_points(self):
|
||||
+ def _property_entry_points_disabled(self):
|
||||
entrypoints = {
|
||||
"pyinstaller40": [
|
||||
"hook-dirs = salt.utils.pyinstaller:get_hook_dirs",
|
||||
@ -1,40 +0,0 @@
|
||||
diff --git a/tests/unit/utils/test_schema.py b/tests/unit/utils/test_schema.py
|
||||
index 8c648f5288..5886813e28 100644
|
||||
--- a/tests/unit/utils/test_schema.py
|
||||
+++ b/tests/unit/utils/test_schema.py
|
||||
@@ -528,7 +528,7 @@ class ConfigTestCase(TestCase):
|
||||
jsonschema.validate(
|
||||
{"personal_access_token": "foo"}, Requirements.serialize()
|
||||
)
|
||||
- if JSONSCHEMA_VERSION >= _LooseVersion("3.0.0"):
|
||||
+ if JSONSCHEMA_VERSION >= _LooseVersion("3.0.0") and JSONSCHEMA_VERSION < _LooseVersion("4.17.0"):
|
||||
self.assertIn(
|
||||
"'ssh_key_file' is a required property", excinfo.exception.message
|
||||
)
|
||||
@@ -1851,7 +1851,7 @@ class ConfigTestCase(TestCase):
|
||||
jsonschema.validate(
|
||||
{"item": {"sides": "4", "color": "blue"}}, TestConf.serialize()
|
||||
)
|
||||
- if JSONSCHEMA_VERSION >= _LooseVersion("3.0.0"):
|
||||
+ if JSONSCHEMA_VERSION >= _LooseVersion("3.0.0") and JSONSCHEMA_VERSION < _LooseVersion("4.17.0"):
|
||||
self.assertIn("'4'", excinfo.exception.message)
|
||||
self.assertIn("is not of type", excinfo.exception.message)
|
||||
self.assertIn("'boolean'", excinfo.exception.message)
|
||||
@@ -1974,7 +1974,7 @@ class ConfigTestCase(TestCase):
|
||||
|
||||
with self.assertRaises(jsonschema.exceptions.ValidationError) as excinfo:
|
||||
jsonschema.validate({"item": ["maybe"]}, TestConf.serialize())
|
||||
- if JSONSCHEMA_VERSION >= _LooseVersion("3.0.0"):
|
||||
+ if JSONSCHEMA_VERSION >= _LooseVersion("3.0.0") and JSONSCHEMA_VERSION < _LooseVersion("4.17.0"):
|
||||
self.assertIn("'maybe'", excinfo.exception.message)
|
||||
self.assertIn("is not one of", excinfo.exception.message)
|
||||
self.assertIn("'yes'", excinfo.exception.message)
|
||||
@@ -2036,7 +2036,7 @@ class ConfigTestCase(TestCase):
|
||||
|
||||
with self.assertRaises(jsonschema.exceptions.ValidationError) as excinfo:
|
||||
jsonschema.validate({"item": ["maybe"]}, TestConf.serialize())
|
||||
- if JSONSCHEMA_VERSION >= _LooseVersion("3.0.0"):
|
||||
+ if JSONSCHEMA_VERSION >= _LooseVersion("3.0.0") and JSONSCHEMA_VERSION < _LooseVersion("4.17.0"):
|
||||
self.assertIn("'maybe'", excinfo.exception.message)
|
||||
self.assertIn("is not one of", excinfo.exception.message)
|
||||
self.assertIn("'yes'", excinfo.exception.message)
|
||||
13
app-admin/salt/files/salt-3006.9-pam-module.patch
Normal file
13
app-admin/salt/files/salt-3006.9-pam-module.patch
Normal file
@ -0,0 +1,13 @@
|
||||
diff --git a/salt/auth/pam.py b/salt/auth/pam.py
|
||||
index 6e179deb7c..935c523606 100644
|
||||
--- a/salt/auth/pam.py
|
||||
+++ b/salt/auth/pam.py
|
||||
@@ -228,7 +228,7 @@ def authenticate(username, password):
|
||||
env["SALT_PAM_PASSWORD"] = password
|
||||
env["SALT_PAM_SERVICE"] = __opts__.get("auth.pam.service", "login")
|
||||
env["SALT_PAM_ENCODING"] = __salt_system_encoding__
|
||||
- pyexe = pathlib.Path(__opts__.get("auth.pam.python", "/usr/bin/python3")).resolve()
|
||||
+ pyexe = pathlib.Path(__opts__.get("auth.pam.python", f"/usr/bin/{os.environ['EPYTHON']}")).resolve()
|
||||
pyfile = pathlib.Path(__file__).resolve()
|
||||
if not pyexe.exists():
|
||||
log.error("Error 'auth.pam.python' config value does not exist: %s", pyexe)
|
||||
@ -0,0 +1,53 @@
|
||||
From 0f69a5a227bfba6ced8a3826d69d556967967fcc Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?=
|
||||
<marmarek@invisiblethingslab.com>
|
||||
Date: Wed, 18 Sep 2024 04:54:24 +0200
|
||||
Subject: [PATCH] Fix Python3.13 compatibility regarding urllib.parse module
|
||||
|
||||
Python 3.13 fixed handling relative paths in urllib.parse module.
|
||||
Specifically, relative file URL is now constructed as file:path instead
|
||||
of converting it to absolute file:///path. This breaks
|
||||
salt.utils.url.create which expects file:/// specifically. The mismatch
|
||||
results in for example changing salt://top.sls into salt://.sls and thus
|
||||
not finding the top file.
|
||||
|
||||
Fix this by handling both prefixes.
|
||||
|
||||
Relevant python change: https://github.com/python/cpython/issues/85110
|
||||
Fixes: #66898
|
||||
---
|
||||
changelog/66898.fixed.md | 1 +
|
||||
salt/utils/url.py | 5 ++---
|
||||
2 files changed, 3 insertions(+), 3 deletions(-)
|
||||
create mode 100644 changelog/66898.fixed.md
|
||||
|
||||
diff --git a/changelog/66898.fixed.md b/changelog/66898.fixed.md
|
||||
new file mode 100644
|
||||
index 000000000000..2549d5e00ed1
|
||||
--- /dev/null
|
||||
+++ b/changelog/66898.fixed.md
|
||||
@@ -0,0 +1 @@
|
||||
+Fixed Python 3.13 compatibility regarding urllib.parse module
|
||||
diff --git a/salt/utils/url.py b/salt/utils/url.py
|
||||
index 478d8e911c2b..839db611c972 100644
|
||||
--- a/salt/utils/url.py
|
||||
+++ b/salt/utils/url.py
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
import re
|
||||
import sys
|
||||
-from urllib.parse import urlparse, urlunparse
|
||||
+from urllib.parse import urlparse, urlunparse, urlunsplit
|
||||
|
||||
import salt.utils.data
|
||||
import salt.utils.path
|
||||
@@ -46,8 +46,7 @@ def create(path, saltenv=None):
|
||||
path = salt.utils.data.decode(path)
|
||||
|
||||
query = f"saltenv={saltenv}" if saltenv else ""
|
||||
- url = salt.utils.data.decode(urlunparse(("file", "", path, "", query, "")))
|
||||
- return "salt://{}".format(url[len("file:///") :])
|
||||
+ return f'salt://{salt.utils.data.decode(urlunsplit(("", "", path, query, "")))}'
|
||||
|
||||
|
||||
def is_escaped(url):
|
||||
43
app-admin/salt/metadata.xml
Normal file
43
app-admin/salt/metadata.xml
Normal file
@ -0,0 +1,43 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
|
||||
<pkgmetadata>
|
||||
<maintainer type="person">
|
||||
<email>chutzpah@gentoo.org</email>
|
||||
<name>Patrick McLean</name>
|
||||
</maintainer>
|
||||
<longdescription lang="en">
|
||||
Salt is a powerful remote execution manager that can be used to administer
|
||||
servers in a fast and efficient way.
|
||||
|
||||
Salt allows commands to be executed across large groups of servers. This means
|
||||
systems can be easily managed, but data can also be easily gathered. Quick
|
||||
introspection into running systems becomes a reality.
|
||||
|
||||
Remote execution is usually used to set up a certain state on a remote system.
|
||||
Salt addresses this problem as well, the salt state system uses salt state
|
||||
files to define the state a server needs to be in.
|
||||
|
||||
Between the remote execution system, and state management Salt addresses the
|
||||
backbone of cloud and data center management.
|
||||
</longdescription>
|
||||
<use>
|
||||
<flag name="cheetah">Enable support for <pkg>dev-python/cheetah3</pkg></flag>
|
||||
<flag name="cherrypy">Enable support for using cherrypy.</flag>
|
||||
<flag name="libcloud">Enable salt-cloud support via libcloud.</flag>
|
||||
<flag name="libvirt">Support managing virtual machines with <pkg>app-emulation/libvirt</pkg>.</flag>
|
||||
<flag name="genshi">Enable support for <pkg>dev-python/genshi</pkg></flag>
|
||||
<flag name="gnupg">Enable support for gnupg via python-gnupg.</flag>
|
||||
<flag name="mako">Add support for using the mako template engine for parsing salt states.</flag>
|
||||
<flag name="mongodb">Support returning data to a mongodb server.</flag>
|
||||
<flag name="neutron">Support the OpenStack neutron network service.</flag>
|
||||
<flag name="nova">Enable support for the OpenStack Nova API</flag>
|
||||
<flag name="openssl">Add support for using TLS via OpenSSL.</flag>
|
||||
<flag name="portage">Add support for package state enforcement using <pkg>sys-apps/portage</pkg></flag>
|
||||
<flag name="raet">Add support for the new RAET transport.</flag>
|
||||
<flag name="redis">Support returning data to a redis database.</flag>
|
||||
<flag name="zeromq">Add support for the zeromq transport.</flag>
|
||||
</use>
|
||||
<upstream>
|
||||
<remote-id type="pypi">salt</remote-id>
|
||||
</upstream>
|
||||
</pkgmetadata>
|
||||
@ -1,219 +0,0 @@
|
||||
# Copyright 1999-2023 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
PYTHON_COMPAT=( python3_{10..11} )
|
||||
|
||||
DISTUTILS_USE_PEP517=setuptools
|
||||
inherit systemd distutils-r1
|
||||
|
||||
DESCRIPTION="Salt is a remote execution and configuration manager"
|
||||
HOMEPAGE="https://www.saltstack.com/resources/community/
|
||||
https://github.com/saltstack"
|
||||
|
||||
if [[ ${PV} == 9999* ]]; then
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://github.com/${PN}stack/${PN}.git"
|
||||
EGIT_BRANCH="develop"
|
||||
else
|
||||
inherit pypi
|
||||
KEYWORDS="amd64 ~arm ~arm64 ~riscv x86"
|
||||
fi
|
||||
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="0"
|
||||
IUSE="
|
||||
cheetah cherrypy ldap libcloud libvirt genshi gnupg keyring mako
|
||||
mongodb neutron nova openssl portage profile redis selinux test raet
|
||||
+zeromq vim-syntax
|
||||
"
|
||||
|
||||
RDEPEND="
|
||||
sys-apps/pciutils
|
||||
>=dev-python/distro-1.5[${PYTHON_USEDEP}]
|
||||
>=dev-python/jinja-3.0.3[${PYTHON_USEDEP}]
|
||||
dev-python/jmespath[${PYTHON_USEDEP}]
|
||||
dev-python/libnacl[${PYTHON_USEDEP}]
|
||||
>=dev-python/msgpack-1.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/psutil-5.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/pycryptodome-3.9.8[${PYTHON_USEDEP}]
|
||||
dev-python/pyyaml[${PYTHON_USEDEP}]
|
||||
>=dev-python/markupsafe-2.0.1[${PYTHON_USEDEP}]
|
||||
>=dev-python/requests-1.0.0[${PYTHON_USEDEP}]
|
||||
dev-python/setuptools[${PYTHON_USEDEP}]
|
||||
dev-python/tomli[${PYTHON_USEDEP}]
|
||||
dev-python/watchdog[${PYTHON_USEDEP}]
|
||||
libcloud? (
|
||||
dev-python/aiohttp[${PYTHON_USEDEP}]
|
||||
dev-python/aiosignal[${PYTHON_USEDEP}]
|
||||
dev-python/async-timeout[${PYTHON_USEDEP}]
|
||||
>=dev-python/libcloud-2.5.0[${PYTHON_USEDEP}]
|
||||
)
|
||||
mako? ( dev-python/mako[${PYTHON_USEDEP}] )
|
||||
ldap? ( dev-python/python-ldap[${PYTHON_USEDEP}] )
|
||||
libvirt? (
|
||||
dev-python/libvirt-python[${PYTHON_USEDEP}]
|
||||
)
|
||||
openssl? (
|
||||
dev-libs/openssl:0=[-bindist(-)]
|
||||
dev-python/pyopenssl[${PYTHON_USEDEP}]
|
||||
)
|
||||
raet? (
|
||||
>=dev-python/libnacl-1.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/ioflo-1.1.7[${PYTHON_USEDEP}]
|
||||
>=dev-python/raet-0.6.0[${PYTHON_USEDEP}]
|
||||
)
|
||||
cherrypy? ( >=dev-python/cherrypy-3.2.2[${PYTHON_USEDEP}] )
|
||||
cheetah? ( >=dev-python/cheetah3-3.2.2[${PYTHON_USEDEP}] )
|
||||
genshi? ( dev-python/genshi[${PYTHON_USEDEP}] )
|
||||
mongodb? ( dev-python/pymongo[${PYTHON_USEDEP}] )
|
||||
portage? ( sys-apps/portage[${PYTHON_USEDEP}] )
|
||||
keyring? ( dev-python/keyring[${PYTHON_USEDEP}] )
|
||||
redis? ( dev-python/redis[${PYTHON_USEDEP}] )
|
||||
selinux? ( sec-policy/selinux-salt )
|
||||
nova? (
|
||||
>=dev-python/python-novaclient-2.17.0[${PYTHON_USEDEP}]
|
||||
)
|
||||
neutron? (
|
||||
>=dev-python/python-neutronclient-2.3.6[${PYTHON_USEDEP}]
|
||||
)
|
||||
gnupg? ( dev-python/python-gnupg[${PYTHON_USEDEP}] )
|
||||
profile? ( dev-python/yappi[${PYTHON_USEDEP}] )
|
||||
vim-syntax? ( app-vim/salt-vim )
|
||||
zeromq? ( >=dev-python/pyzmq-19.0.0[${PYTHON_USEDEP}] )
|
||||
"
|
||||
BDEPEND="
|
||||
test? (
|
||||
${RDEPEND}
|
||||
>=dev-python/boto-2.32.1[${PYTHON_USEDEP}]
|
||||
dev-python/certifi[${PYTHON_USEDEP}]
|
||||
dev-python/cherrypy[${PYTHON_USEDEP}]
|
||||
>=dev-python/jsonschema-3.0[${PYTHON_USEDEP}]
|
||||
dev-python/mako[${PYTHON_USEDEP}]
|
||||
>=dev-python/mock-2.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/moto-2.0.0[${PYTHON_USEDEP}]
|
||||
dev-python/passlib
|
||||
dev-python/pip[${PYTHON_USEDEP}]
|
||||
dev-python/pyopenssl[${PYTHON_USEDEP}]
|
||||
>=dev-python/pytest-7.0.1[${PYTHON_USEDEP}]
|
||||
>=dev-python/pytest-salt-factories-1.0.0_rc17[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-tempdir[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-helpers-namespace[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-subtests[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-shell-utilities[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-skip-markers[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-system-statistics[${PYTHON_USEDEP}]
|
||||
dev-python/flaky[${PYTHON_USEDEP}]
|
||||
dev-python/libcloud[${PYTHON_USEDEP}]
|
||||
net-dns/bind-tools
|
||||
>=dev-python/virtualenv-20.3.0[${PYTHON_USEDEP}]
|
||||
dev-util/yamllint[${PYTHON_USEDEP}]
|
||||
!x86? ( >=dev-python/boto3-1.17.67[${PYTHON_USEDEP}] )
|
||||
)
|
||||
"
|
||||
|
||||
DOCS=( README.rst AUTHORS )
|
||||
|
||||
REQUIRED_USE="|| ( raet zeromq )
|
||||
test? ( cheetah genshi )"
|
||||
RESTRICT="!test? ( test ) x86? ( test )"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/salt-3003-skip-tests-that-oom-machine.patch"
|
||||
"${FILESDIR}/salt-3003-gentoolkit-revdep.patch"
|
||||
"${FILESDIR}/salt-3002-tests.patch"
|
||||
"${FILESDIR}/salt-3003.1-tests.patch"
|
||||
"${FILESDIR}/salt-3005-relax-pyzmq-dep.patch"
|
||||
"${FILESDIR}/salt-3005-tests.patch"
|
||||
"${FILESDIR}/salt-3005.1-no-entry-points.patch"
|
||||
"${FILESDIR}/salt-3005.1-importlib-metadata-5-r1.patch"
|
||||
"${FILESDIR}/salt-3005.1-tests.patch"
|
||||
"${FILESDIR}/salt-3005.1-modules-file-python-3.11-host.patch"
|
||||
)
|
||||
|
||||
python_prepare_all() {
|
||||
# remove tests with external dependencies that may not be available, and
|
||||
# tests that don't work in sandbox
|
||||
rm tests/unit/{test_{zypp_plugins,module_names},utils/test_extend}.py || die
|
||||
rm tests/unit/modules/test_boto_{vpc,secgroup,elb}.py || die
|
||||
rm tests/unit/states/test_boto_vpc.py || die
|
||||
rm tests/support/gitfs.py tests/unit/runners/test_git_pillar.py || die
|
||||
rm tests/pytests/functional/transport/server/test_req_channel.py || die
|
||||
rm tests/pytests/functional/utils/test_async_event_publisher.py || die
|
||||
rm tests/pytests/functional/runners/test_winrepo.py || die
|
||||
|
||||
# tests that require network access
|
||||
rm tests/unit/{states,modules}/test_zcbuildout.py || die
|
||||
rm -r tests/integration/cloud || die
|
||||
rm -r tests/kitchen/tests/wordpress/tests || die
|
||||
rm tests/kitchen/test_kitchen.py || die
|
||||
rm tests/unit/modules/test_network.py || die
|
||||
rm tests/pytests/functional/modules/test_pip.py || die
|
||||
rm tests/pytests/unit/client/ssh/test_ssh.py || die
|
||||
rm -r tests/pytests/{integration,functional}/netapi tests/integration/netapi || die
|
||||
|
||||
# tests require root access
|
||||
rm tests/integration/pillar/test_git_pillar.py || die
|
||||
rm tests/integration/states/test_supervisord.py || die
|
||||
|
||||
# removes contextvars, see bug: https://bugs.gentoo.org/799431
|
||||
sed -i '/^contextvars/d' requirements/base.txt || die
|
||||
|
||||
# make sure pkg_resources doesn't bomb because pycrypto isn't installed
|
||||
find "${S}" -name '*.txt' -print0 | xargs -0 sed -e '/pycrypto>/ d ; /pycryptodomex/ d' -i || die
|
||||
# pycryptodome rather than pycryptodomex
|
||||
find "${S}" -name '*.py' -print0 | xargs -0 -- sed -i -e 's:Cryptodome:Crypto:g' -- || die
|
||||
|
||||
distutils-r1_python_prepare_all
|
||||
}
|
||||
|
||||
python_install_all() {
|
||||
local svc
|
||||
USE_SETUPTOOLS=1 distutils-r1_python_install_all
|
||||
|
||||
for svc in minion master syndic api; do
|
||||
newinitd "${FILESDIR}"/${svc}-initd-5 salt-${svc}
|
||||
newconfd "${FILESDIR}"/${svc}-confd-1 salt-${svc}
|
||||
systemd_dounit "${FILESDIR}"/salt-${svc}.service
|
||||
done
|
||||
|
||||
insinto /etc/${PN}
|
||||
doins -r conf/*
|
||||
}
|
||||
|
||||
python_test() {
|
||||
# testsuite likes lots of files
|
||||
ulimit -n 4096 || die
|
||||
|
||||
local -a disable_tests=(
|
||||
# doesn't like the distutils warning
|
||||
batch_retcode
|
||||
multiple_modules_in_batch
|
||||
# hangs indefinitely
|
||||
master_type_disable
|
||||
# needs root
|
||||
runas_env_sudo_group
|
||||
# don't like sandbox
|
||||
split_multibyte_characters_{shiftjis,unicode}
|
||||
# doesn't like sandbox env
|
||||
log_sanitize
|
||||
)
|
||||
local textexpr
|
||||
testexpr=$(printf 'not %s and ' "${disable_tests[@]}")
|
||||
|
||||
# ${T} is too long a path for the tests to work
|
||||
local TMPDIR
|
||||
TMPDIR="$(mktemp --directory --tmpdir=/tmp ${PN}-XXXX)" || die
|
||||
(
|
||||
export TMPDIR
|
||||
cleanup() { rm -rf "${TMPDIR}" || die; }
|
||||
|
||||
trap cleanup EXIT
|
||||
|
||||
addwrite "${TMPDIR}"
|
||||
|
||||
USE_SETUPTOOLS=1 NO_INTERNET=1 SHELL="/bin/bash" \
|
||||
"${EPYTHON}" -m pytest -vv -k "${testexpr%and }" \
|
||||
|| die "testing failed with ${EPYTHON}"
|
||||
)
|
||||
}
|
||||
606
app-admin/salt/salt-3007.2.ebuild
Normal file
606
app-admin/salt/salt-3007.2.ebuild
Normal file
@ -0,0 +1,606 @@
|
||||
# Copyright 1999-2025 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
PYTHON_COMPAT=( python3_1{1..3} )
|
||||
|
||||
DISTUTILS_USE_PEP517=setuptools
|
||||
inherit systemd distutils-r1
|
||||
|
||||
DESCRIPTION="Salt is a remote execution and configuration manager"
|
||||
HOMEPAGE="https://www.saltstack.com/resources/community/
|
||||
https://github.com/saltstack"
|
||||
|
||||
if [[ ${PV} == 9999* ]]; then
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://github.com/${PN}stack/${PN}.git"
|
||||
EGIT_BRANCH="develop"
|
||||
else
|
||||
inherit pypi
|
||||
KEYWORDS="~amd64 ~riscv ~x86"
|
||||
fi
|
||||
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="0"
|
||||
IUSE="
|
||||
cheetah cherrypy ldap libcloud libvirt genshi gnupg keyring mako
|
||||
mongodb neutron nova portage profile redis selinux test raet
|
||||
+zeromq vim-syntax
|
||||
"
|
||||
|
||||
RDEPEND="
|
||||
sys-apps/pciutils
|
||||
dev-libs/openssl:0=[-bindist(-)]
|
||||
dev-python/aiohttp[${PYTHON_USEDEP}]
|
||||
>=dev-python/cherrypy-18.6.1[${PYTHON_USEDEP}]
|
||||
>=dev-python/cryptography-42.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/distro-1.5[${PYTHON_USEDEP}]
|
||||
dev-python/importlib-metadata[${PYTHON_USEDEP}]
|
||||
>=dev-python/jinja2-3.1.3[${PYTHON_USEDEP}]
|
||||
dev-python/jmespath[${PYTHON_USEDEP}]
|
||||
dev-python/libnacl[${PYTHON_USEDEP}]
|
||||
dev-python/looseversion[${PYTHON_USEDEP}]
|
||||
>=dev-python/msgpack-1.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/packaging-21.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/psutil-5.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/pycryptodome-3.19.1[${PYTHON_USEDEP}]
|
||||
>=dev-python/pyopenssl-24.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/python-dateutil-2.8.1[${PYTHON_USEDEP}]
|
||||
dev-python/python-gnupg[${PYTHON_USEDEP}]
|
||||
>=dev-python/pyyaml-6.0.1[${PYTHON_USEDEP}]
|
||||
>=dev-python/markupsafe-2.1.2[${PYTHON_USEDEP}]
|
||||
>=dev-python/requests-2.31.0[${PYTHON_USEDEP}]
|
||||
dev-python/setproctitle[${PYTHON_USEDEP}]
|
||||
dev-python/setuptools[${PYTHON_USEDEP}]
|
||||
dev-python/tomli[${PYTHON_USEDEP}]
|
||||
dev-python/tornado[${PYTHON_USEDEP}]
|
||||
dev-python/watchdog[${PYTHON_USEDEP}]
|
||||
libcloud? (
|
||||
>=dev-python/aiohttp-3.9.0[${PYTHON_USEDEP}]
|
||||
dev-python/aiosignal[${PYTHON_USEDEP}]
|
||||
>=dev-python/apache-libcloud-2.5.0[${PYTHON_USEDEP}]
|
||||
dev-python/async-timeout[${PYTHON_USEDEP}]
|
||||
)
|
||||
mako? ( dev-python/mako[${PYTHON_USEDEP}] )
|
||||
ldap? ( dev-python/python-ldap[${PYTHON_USEDEP}] )
|
||||
libvirt? (
|
||||
dev-python/libvirt-python[${PYTHON_USEDEP}]
|
||||
)
|
||||
raet? (
|
||||
>=dev-python/libnacl-1.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/ioflo-1.1.7[${PYTHON_USEDEP}]
|
||||
>=dev-python/raet-0.6.0[${PYTHON_USEDEP}]
|
||||
)
|
||||
cheetah? ( >=dev-python/cheetah3-3.2.2[${PYTHON_USEDEP}] )
|
||||
genshi? ( dev-python/genshi[${PYTHON_USEDEP}] )
|
||||
mongodb? ( dev-python/pymongo[${PYTHON_USEDEP}] )
|
||||
portage? ( sys-apps/portage[${PYTHON_USEDEP}] )
|
||||
keyring? ( dev-python/keyring[${PYTHON_USEDEP}] )
|
||||
redis? ( dev-python/redis[${PYTHON_USEDEP}] )
|
||||
selinux? ( sec-policy/selinux-salt )
|
||||
nova? ( >=dev-python/python-novaclient-2.17.0[${PYTHON_USEDEP}] )
|
||||
neutron? ( >=dev-python/python-neutronclient-2.3.6[${PYTHON_USEDEP}] )
|
||||
gnupg? ( dev-python/python-gnupg[${PYTHON_USEDEP}] )
|
||||
profile? ( dev-python/yappi[${PYTHON_USEDEP}] )
|
||||
vim-syntax? ( app-vim/salt-vim )
|
||||
zeromq? ( >=dev-python/pyzmq-19.0.0[${PYTHON_USEDEP}] )
|
||||
"
|
||||
BDEPEND="
|
||||
sys-apps/findutils
|
||||
dev-python/build[${PYTHON_USEDEP}]
|
||||
test? (
|
||||
${RDEPEND}
|
||||
app-arch/zip
|
||||
dev-python/apache-libcloud[${PYTHON_USEDEP}]
|
||||
dev-python/boto3[${PYTHON_USEDEP}]
|
||||
>=dev-python/certifi-2023.07.22[${PYTHON_USEDEP}]
|
||||
dev-python/cherrypy[${PYTHON_USEDEP}]
|
||||
>=dev-python/jsonschema-3.0[${PYTHON_USEDEP}]
|
||||
dev-python/mako[${PYTHON_USEDEP}]
|
||||
>=dev-python/mock-2.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/moto-2.0.0[${PYTHON_USEDEP}]
|
||||
<dev-python/moto-5[${PYTHON_USEDEP}]
|
||||
dev-python/passlib[${PYTHON_USEDEP}]
|
||||
dev-python/bcrypt[${PYTHON_USEDEP}]
|
||||
dev-python/pip[${PYTHON_USEDEP}]
|
||||
dev-python/pygit2[${PYTHON_USEDEP}]
|
||||
dev-python/pyinotify[${PYTHON_USEDEP}]
|
||||
>=dev-python/pyopenssl-23.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/pytest-7.2.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/pytest-salt-factories-1.0.0_rc29[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-tempdir[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-helpers-namespace[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-subtests[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-shell-utilities[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-skip-markers[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-system-statistics[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-custom-exit-code[${PYTHON_USEDEP}]
|
||||
dev-python/flaky[${PYTHON_USEDEP}]
|
||||
net-dns/bind-tools
|
||||
>=dev-python/virtualenv-20.3.0[${PYTHON_USEDEP}]
|
||||
dev-util/yamllint[${PYTHON_USEDEP}]
|
||||
!x86? ( >=dev-python/boto3-1.21.46[${PYTHON_USEDEP}] )
|
||||
)
|
||||
"
|
||||
|
||||
DOCS=( README.rst AUTHORS )
|
||||
|
||||
REQUIRED_USE="
|
||||
|| ( raet zeromq )
|
||||
test? ( cheetah genshi )
|
||||
"
|
||||
RESTRICT="
|
||||
!test? ( test )
|
||||
x86? ( test )
|
||||
"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/salt-3003-gentoolkit-revdep.patch"
|
||||
"${FILESDIR}/salt-3006.9-pam-module.patch"
|
||||
"${FILESDIR}/salt-3007.1-python-3.13-urllib-parse.patch"
|
||||
)
|
||||
|
||||
python_prepare_all() {
|
||||
local -a remove_test_files=(
|
||||
# remove tests with external dependencies that may not be available, and
|
||||
# tests that don't work in sandbox
|
||||
tests/integration/externalapi/test_venafiapi.py
|
||||
tests/integration/modules/test_rabbitmq.py
|
||||
tests/integration/modules/test_supervisord.py
|
||||
tests/integration/states/test_match.py
|
||||
tests/pytests/functional/fileserver/hgfs/test_hgfs.py
|
||||
tests/pytests/functional/loader/test_loader.py
|
||||
tests/pytests/functional/modules/file/test_readlink.py
|
||||
tests/pytests/functional/modules/file/test_symlink.py
|
||||
tests/pytests/functional/modules/state/test_jinja_filters.py
|
||||
tests/pytests/functional/modules/state/test_jinja_renderer.py
|
||||
tests/pytests/functional/modules/state/test_mako_renderer.py
|
||||
tests/pytests/functional/modules/state/test_pyobjects_renderer.py
|
||||
tests/pytests/functional/modules/test_aptpkg.py
|
||||
tests/pytests/functional/modules/test_dockermod.py
|
||||
tests/pytests/functional/modules/test_etcd_mod.py
|
||||
tests/pytests/functional/modules/test_grains.py
|
||||
tests/pytests/functional/modules/test_mac_service.py
|
||||
tests/pytests/functional/modules/test_saltcheck.py
|
||||
tests/pytests/functional/modules/test_saltutil.py
|
||||
tests/pytests/functional/modules/test_test.py
|
||||
tests/pytests/functional/pillar/hg_pillar/test_hg_pillar.py
|
||||
tests/pytests/functional/pillar/test_git_pillar.py
|
||||
tests/pytests/functional/pillar/test_gpg.py
|
||||
tests/pytests/functional/returners/test_etcd_return.py
|
||||
tests/pytests/functional/runners/test_winrepo.py
|
||||
tests/pytests/functional/sdb/test_etcd_db.py
|
||||
tests/pytests/functional/state/test_masterless_tops.py
|
||||
tests/pytests/functional/states/file/test_keyvalue.py
|
||||
tests/pytests/functional/states/file/test_patch.py
|
||||
tests/pytests/functional/states/file/test_rename.py
|
||||
tests/pytests/functional/states/rabbitmq
|
||||
tests/pytests/functional/states/test_docker_container.py
|
||||
tests/pytests/functional/states/test_docker_network.py
|
||||
tests/pytests/functional/states/test_etcd_mod.py
|
||||
tests/pytests/functional/states/test_module.py
|
||||
tests/pytests/functional/states/test_mysql.py
|
||||
tests/pytests/functional/states/test_svn.py
|
||||
tests/pytests/functional/states/test_virtualenv_mod.py
|
||||
tests/pytests/functional/test_version.py
|
||||
tests/pytests/functional/utils/gitfs
|
||||
tests/pytests/functional/utils/test_vault.py
|
||||
tests/pytests/integration/cli/test_syndic_eauth.py
|
||||
tests/pytests/integration/daemons/test_memory_leak.py
|
||||
tests/pytests/integration/grains/test_grains.py
|
||||
tests/pytests/integration/master/test_clear_funcs.py
|
||||
tests/pytests/integration/minion/test_reauth.py
|
||||
tests/pytests/integration/modules/grains/test_append.py
|
||||
tests/pytests/integration/modules/grains/test_module.py
|
||||
tests/pytests/integration/modules/saltutil/test_grains.py
|
||||
tests/pytests/integration/modules/saltutil/test_modules.py
|
||||
tests/pytests/integration/modules/saltutil/test_wheel.py
|
||||
tests/pytests/integration/modules/state/test_state_pillar_errors.py
|
||||
tests/pytests/integration/modules/state/test_state_test.py
|
||||
tests/pytests/integration/modules/test_cmdmod.py
|
||||
tests/pytests/integration/modules/test_event.py
|
||||
tests/pytests/integration/modules/test_file.py
|
||||
tests/pytests/integration/modules/test_jinja.py
|
||||
tests/pytests/integration/modules/test_pillar.py
|
||||
tests/pytests/integration/modules/test_vault.py
|
||||
tests/pytests/integration/modules/test_virt.py
|
||||
tests/pytests/integration/modules/test_x509_v2.py
|
||||
tests/pytests/integration/proxy/test_deltaproxy.py
|
||||
tests/pytests/integration/proxy/test_shell.py
|
||||
tests/pytests/integration/reactor/test_reactor.py
|
||||
tests/pytests/integration/returners/test_noop_return.py
|
||||
tests/pytests/integration/runners/state/orchestrate/test_orchestrate.py
|
||||
tests/pytests/integration/runners/test_cache.py
|
||||
tests/pytests/integration/runners/test_jobs.py
|
||||
tests/pytests/integration/runners/test_manage.py
|
||||
tests/pytests/integration/runners/test_saltutil.py
|
||||
tests/pytests/integration/runners/test_vault.py
|
||||
tests/pytests/integration/sdb/test_vault.py
|
||||
tests/pytests/integration/ssh/state/test_pillar_override.py
|
||||
tests/pytests/integration/ssh/state/test_retcode_highstate_verification_requisite_fail.py
|
||||
tests/pytests/integration/ssh/state/test_retcode_pillar_render_exception.py
|
||||
tests/pytests/integration/ssh/state/test_retcode_render_exception.py
|
||||
tests/pytests/integration/ssh/state/test_retcode_render_module_exception.py
|
||||
tests/pytests/integration/ssh/state/test_retcode_run_fail.py
|
||||
tests/pytests/integration/ssh/state/test_retcode_state_run_remote_exception.py
|
||||
tests/pytests/integration/ssh/state/test_state.py
|
||||
tests/pytests/integration/ssh/state/test_with_import_dir.py
|
||||
tests/pytests/integration/ssh/test_cmdmod.py
|
||||
tests/pytests/integration/ssh/test_config.py
|
||||
tests/pytests/integration/ssh/test_cp.py
|
||||
tests/pytests/integration/ssh/test_deploy.py
|
||||
tests/pytests/integration/ssh/test_grains.py
|
||||
tests/pytests/integration/ssh/test_jinja_mods.py
|
||||
tests/pytests/integration/ssh/test_master.py
|
||||
tests/pytests/integration/ssh/test_mine.py
|
||||
tests/pytests/integration/ssh/test_pillar.py
|
||||
tests/pytests/integration/ssh/test_pillar_compilation.py
|
||||
tests/pytests/integration/ssh/test_pre_flight.py
|
||||
tests/pytests/integration/ssh/test_publish.py
|
||||
tests/pytests/integration/ssh/test_py_versions.py
|
||||
tests/pytests/integration/ssh/test_raw.py
|
||||
tests/pytests/integration/ssh/test_saltcheck.py
|
||||
tests/pytests/integration/ssh/test_slsutil.py
|
||||
tests/pytests/integration/states/test_beacon.py
|
||||
tests/pytests/integration/states/test_file.py
|
||||
tests/pytests/integration/states/test_include.py
|
||||
tests/pytests/integration/states/test_ini_manage.py
|
||||
tests/pytests/integration/states/test_state_test.py
|
||||
tests/pytests/integration/states/test_x509_v2.py
|
||||
tests/pytests/integration/utils/test_templates.py
|
||||
tests/pytests/integration/wheel/test_key.py
|
||||
tests/pytests/pkg/integration/test_check_imports.py
|
||||
tests/pytests/pkg/integration/test_clean_zmq_teardown.py
|
||||
tests/pytests/pkg/integration/test_enabled_disabled.py
|
||||
tests/pytests/pkg/integration/test_help.py
|
||||
tests/pytests/pkg/integration/test_logrotate_config.py
|
||||
tests/pytests/pkg/integration/test_pip.py
|
||||
tests/pytests/pkg/integration/test_pkg.py
|
||||
tests/pytests/pkg/integration/test_python.py
|
||||
tests/pytests/scenarios/compat/test_with_versions.py
|
||||
tests/pytests/unit/loader/test_lazy.py
|
||||
tests/pytests/unit/modules/test_mongodb.py
|
||||
tests/pytests/unit/modules/test_mysql.py
|
||||
tests/pytests/unit/modules/test_schedule.py
|
||||
tests/pytests/unit/modules/test_yaml.py
|
||||
tests/pytests/unit/pillar/test_consul_pillar.py
|
||||
tests/pytests/unit/pillar/test_mysql.py
|
||||
tests/pytests/unit/pillar/test_pillar.py
|
||||
tests/pytests/unit/renderers/test_yamlex.py
|
||||
tests/pytests/unit/roster/test_ansible.py
|
||||
tests/pytests/unit/roster/test_dir.py
|
||||
tests/pytests/unit/runners/test_reactor.py
|
||||
tests/pytests/unit/states/file/test_keyvalue.py
|
||||
tests/pytests/unit/utils/jinja/test_get_template.py
|
||||
tests/pytests/unit/utils/jinja/test_salt_cache_loader.py
|
||||
tests/pytests/unit/utils/test_cache.py
|
||||
tests/pytests/unit/utils/test_etcd_util.py
|
||||
tests/pytests/unit/utils/test_package.py
|
||||
tests/pytests/unit/utils/test_versions.py
|
||||
tests/pytests/unit/utils/test_x509.py
|
||||
tests/unit/ext/test_ipaddress.py
|
||||
tests/unit/modules/test_boto_elb.py
|
||||
tests/unit/modules/test_boto_secgroup.py
|
||||
tests/unit/modules/test_boto_vpc.py
|
||||
tests/unit/modules/test_elasticsearch.py
|
||||
tests/unit/modules/test_k8s.py
|
||||
tests/unit/modules/test_kubernetesmod.py
|
||||
tests/unit/modules/test_vsphere.py
|
||||
tests/unit/netapi/rest_tornado/test_saltnado.py
|
||||
tests/unit/states/test_boto_vpc.py
|
||||
tests/unit/test_module_names.py
|
||||
tests/unit/test_zypp_plugins.py
|
||||
tests/unit/utils/test_extend.py
|
||||
tests/unit/utils/test_pbm.py
|
||||
tests/unit/utils/test_schema.py
|
||||
tests/unit/utils/test_vmware.py
|
||||
tests/unit/utils/test_vsan.py
|
||||
|
||||
# tests that require network access
|
||||
tests/integration/cloud
|
||||
tests/integration/netapi
|
||||
tests/pytests/functional/cli/test_salt_cloud.py
|
||||
tests/pytests/functional/cli/test_salt_run_.py
|
||||
tests/pytests/functional/modules/test_ansiblegate.py
|
||||
tests/pytests/functional/modules/test_http.py
|
||||
tests/pytests/functional/netapi
|
||||
tests/pytests/functional/states/test_pip_state.py
|
||||
tests/pytests/functional/utils/test_etcd_util.py
|
||||
tests/pytests/functional/utils/test_http.py
|
||||
tests/pytests/integration/cli/test_salt_proxy.py
|
||||
tests/pytests/integration/daemons/test_masterapi.py
|
||||
tests/pytests/integration/modules/state/test_state.py
|
||||
tests/pytests/integration/modules/state/test_state_state_events.py
|
||||
tests/pytests/integration/netapi
|
||||
tests/pytests/integration/pillar/cache/test_pillar_cache.py
|
||||
tests/pytests/integration/pillar/test_fileclient.py
|
||||
tests/pytests/integration/pillar/test_pillar_include.py
|
||||
tests/pytests/integration/proxy/test_simple.py
|
||||
tests/pytests/integration/runners/state/orchestrate/test_events.py
|
||||
tests/pytests/integration/wheel/test_pillar_roots.py
|
||||
tests/pytests/pkg/downgrade/test_salt_downgrade.py
|
||||
tests/pytests/pkg/integration/test_pip_upgrade.py
|
||||
tests/pytests/pkg/integration/test_salt_api.py
|
||||
tests/pytests/pkg/integration/test_salt_call.py
|
||||
tests/pytests/pkg/integration/test_salt_exec.py
|
||||
tests/pytests/pkg/integration/test_salt_grains.py
|
||||
tests/pytests/pkg/integration/test_salt_key.py
|
||||
tests/pytests/pkg/integration/test_salt_minion.py
|
||||
tests/pytests/pkg/integration/test_salt_output.py
|
||||
tests/pytests/pkg/integration/test_salt_pillar.py
|
||||
tests/pytests/pkg/integration/test_salt_state_file.py
|
||||
tests/pytests/pkg/integration/test_salt_ufw.py
|
||||
tests/pytests/pkg/integration/test_salt_user.py
|
||||
tests/pytests/pkg/integration/test_systemd_config.py
|
||||
tests/pytests/pkg/integration/test_version.py
|
||||
tests/pytests/pkg/upgrade/test_salt_upgrade.py
|
||||
tests/pytests/scenarios/cluster/test_cluster.py
|
||||
tests/pytests/scenarios/dns/multimaster/test_dns.py
|
||||
tests/pytests/scenarios/dns/test_dns.py
|
||||
tests/pytests/unit/client/ssh/test_ssh.py
|
||||
tests/pytests/unit/cloud/clouds/vmware
|
||||
tests/pytests/unit/loader/test_loading_modules.py
|
||||
tests/pytests/unit/runners/test_net.py
|
||||
tests/pytests/unit/states/file/test_mod_beacon.py
|
||||
tests/pytests/unit/test_client.py
|
||||
tests/pytests/unit/utils/test_aws.py
|
||||
tests/pytests/unit/utils/test_http.py
|
||||
tests/unit/modules/test_boto3_elasticsearch.py
|
||||
tests/unit/modules/test_boto3_route53.py
|
||||
tests/unit/modules/test_network.py
|
||||
tests/unit/modules/test_zcbuildout.py
|
||||
tests/unit/states/test_zcbuildout.py
|
||||
|
||||
# tests require root access
|
||||
tests/integration/pillar/test_git_pillar.py
|
||||
tests/integration/states/test_lxd_container.py
|
||||
tests/integration/states/test_lxd_image.py
|
||||
tests/integration/states/test_lxd_profile.py
|
||||
tests/integration/states/test_supervisord.py
|
||||
tests/pytests/functional/cache/test_mysql.py
|
||||
tests/pytests/functional/cli/test_salt.py
|
||||
tests/pytests/functional/modules/test_mysql.py
|
||||
tests/pytests/functional/modules/test_vault.py
|
||||
tests/pytests/functional/states/file/test_accumulated.py
|
||||
tests/pytests/scenarios/performance/test_performance.py
|
||||
tests/pytests/unit/cloud/test_map.py
|
||||
tests/pytests/unit/engines/test_slack_bolt_engine.py
|
||||
tests/pytests/unit/modules/state/test_state.py
|
||||
tests/pytests/unit/modules/state/test_top_file_merge.py
|
||||
tests/pytests/unit/proxy/test_netmiko_px.py
|
||||
tests/pytests/unit/proxy/test_ssh_sample.py
|
||||
tests/pytests/unit/roster/test_sshknownhosts.py
|
||||
|
||||
# tests that require boto
|
||||
tests/pytests/unit/engines/test_sqs_events.py
|
||||
|
||||
# first test always fails
|
||||
tests/pytests/unit/utils/parsers/test_log_parsers.py
|
||||
)
|
||||
|
||||
rm -r "${remove_test_files[@]}" || die
|
||||
|
||||
# axe the boto dep (bug #888235)
|
||||
find "${S}/tests" -name 'test_boto_*.py' -delete || die
|
||||
|
||||
# removes contextvars, see bug: https://bugs.gentoo.org/799431
|
||||
sed -i '/^contextvars/d' requirements/base.txt || die
|
||||
|
||||
# called_once should be assert_called_once_with
|
||||
find "${S}/tests" -name '*.py' -print0 \
|
||||
| xargs -0 -- sed -i -e 's:[.]called_once:.assert_called_once:g' -- || die
|
||||
|
||||
distutils-r1_python_prepare_all
|
||||
}
|
||||
|
||||
python_install_all() {
|
||||
local -x USE_SETUPTOOLS=1
|
||||
distutils-r1_python_install_all
|
||||
|
||||
local svc
|
||||
for svc in minion master syndic api; do
|
||||
newinitd "${FILESDIR}"/${svc}-initd-5 salt-${svc}
|
||||
newconfd "${FILESDIR}"/${svc}-confd-1 salt-${svc}
|
||||
systemd_dounit "${FILESDIR}"/salt-${svc}.service
|
||||
done
|
||||
|
||||
insinto /etc/${PN}
|
||||
doins -r conf/*
|
||||
}
|
||||
|
||||
python_test() {
|
||||
local -a EPYTEST_DESELECT=(
|
||||
# doesn't like the distutils warning
|
||||
tests/pytests/integration/cli/test_batch.py::test_batch_retcode
|
||||
tests/pytests/integration/cli/test_batch.py::test_multiple_modules_in_batch
|
||||
|
||||
# hangs indefinitely
|
||||
tests/pytests/unit/test_minion.py::test_master_type_disable
|
||||
|
||||
# needs root
|
||||
tests/pytests/unit/modules/test_cmdmod.py::test_runas_env_sudo_group
|
||||
tests/pytests/unit/modules/test_portage_config.py::test_enforce_nice_config
|
||||
tests/unit/modules/test_saltcheck.py::SaltcheckTestCase::test_run_test_muliassert
|
||||
tests/unit/modules/test_saltcheck.py::SaltcheckTestCase::test_run_test_muliassert_failure
|
||||
|
||||
# don't like sandbox
|
||||
tests/integration/modules/test_cp.py::CPModuleTest::test_get_file_str_https
|
||||
tests/integration/modules/test_cp.py::CPModuleTest::test_get_url_ftp
|
||||
tests/integration/modules/test_cp.py::CPModuleTest::test_get_url_https
|
||||
tests/integration/modules/test_cp.py::CPModuleTest::test_get_url_https_dest_empty
|
||||
tests/integration/modules/test_cp.py::CPModuleTest::test_get_url_https_no_dest
|
||||
tests/integration/states/test_git.py::LocalRepoGitTest::test_latest_force_reset_true_fast_forward
|
||||
tests/pytests/functional/fileserver/test_roots.py::test_symlink_list
|
||||
tests/pytests/functional/modules/file/test_replace.py::test_append_if_not_found_content
|
||||
tests/pytests/functional/modules/file/test_replace.py::test_append_if_not_found_empty_file
|
||||
tests/pytests/functional/modules/file/test_replace.py::test_append_if_not_found_no_append_on_match
|
||||
tests/pytests/functional/modules/file/test_replace.py::test_append_if_not_found_no_match_newline
|
||||
tests/pytests/functional/modules/file/test_replace.py::test_append_if_not_found_no_match_no_newline
|
||||
tests/pytests/functional/modules/test_defaults.py::test_defaults_get
|
||||
tests/pytests/functional/modules/test_system.py::test_get_system_date_time
|
||||
tests/pytests/functional/modules/test_system.py::test_get_system_date_time_utc
|
||||
tests/pytests/functional/pillar/test_top.py::test_pillar_top_compound_match
|
||||
tests/pytests/functional/states/file/test_append.py::test_file_append_check_cmd
|
||||
tests/pytests/functional/states/file/test_append.py::test_issue_1896_file_append_source
|
||||
tests/pytests/functional/states/file/test_blockreplace.py::test_issue_49043
|
||||
tests/pytests/functional/states/file/test_comment.py::test_issue_62121
|
||||
tests/pytests/functional/states/file/test_directory.py::test_directory_clean_require_in
|
||||
tests/pytests/functional/states/file/test_directory.py::test_directory_clean_require_in_with_id
|
||||
tests/pytests/functional/states/file/test_directory.py::test_directory_clean_require_with_name
|
||||
tests/pytests/functional/states/file/test_managed.py::test_file_managed_requisites
|
||||
tests/pytests/functional/states/file/test_managed.py::test_issue_8947_utf8_sls
|
||||
tests/pytests/functional/states/file/test_managed.py::test_managed_escaped_file_path
|
||||
tests/pytests/functional/states/file/test_managed.py::test_managed_file_issue_51208
|
||||
tests/pytests/functional/states/file/test_managed.py::test_managed_file_with_grains_data
|
||||
tests/pytests/functional/states/file/test_managed.py::test_managed_latin1_diff
|
||||
tests/pytests/functional/states/file/test_managed.py::test_managed_source_hash_indifferent_case
|
||||
tests/pytests/functional/states/file/test_managed.py::test_managed_unicode_jinja_with_tojson_filter
|
||||
tests/pytests/functional/states/file/test_recurse.py::test_issue_2726_mode_kwarg
|
||||
tests/pytests/functional/states/file/test_replace.py::test_file_replace_check_cmd
|
||||
tests/pytests/functional/states/file/test_replace.py::test_file_replace_prerequired_issues_55775
|
||||
tests/pytests/functional/states/test_pip_state.py::test_22359_pip_installed_unless_does_not_trigger_warnings
|
||||
tests/pytests/functional/states/test_pip_state.py::test_issue_2028_pip_installed_state
|
||||
tests/pytests/functional/states/test_pip_state.py::test_issue_54755
|
||||
tests/pytests/functional/states/test_pip_state.py::test_pip_installed_errors
|
||||
tests/pytests/functional/states/test_pip_state.py::test_pip_installed_removed
|
||||
tests/pytests/functional/states/test_pip_state.py::test_pip_installed_removed_venv
|
||||
tests/pytests/functional/states/test_pip_state.py::test_pip_installed_specific_env
|
||||
tests/pytests/functional/states/test_x509_v2.py::"test_private_key_managed_passphrase_changed_not_overwrite[existing_pk0]"
|
||||
tests/pytests/functional/utils/functools/test_namespaced_function.py::test_namespacing
|
||||
tests/pytests/functional/utils/test_pillar.py::test_gitpython_env
|
||||
tests/pytests/functional/utils/test_pillar.py::test_gitpython_fetch_request
|
||||
tests/pytests/functional/utils/test_pillar.py::test_gitpython_multiple_repos
|
||||
tests/pytests/functional/utils/test_pillar.py::test_pygit2_env
|
||||
tests/pytests/functional/utils/test_pillar.py::test_pygit2_multiple_repos
|
||||
tests/pytests/functional/utils/test_winrepo.py::test_gitpython_winrepo_simple
|
||||
tests/pytests/functional/utils/test_winrepo.py::test_pygit2_winrepo_simple
|
||||
tests/pytests/integration/minion/test_return_retries.py::test_pillar_timeout
|
||||
tests/pytests/integration/minion/test_return_retries.py::test_publish_retry
|
||||
tests/pytests/integration/modules/saltutil/test_pillar.py::"test_pillar_refresh[False]"
|
||||
tests/pytests/integration/modules/saltutil/test_pillar.py::"test_pillar_refresh[True]"
|
||||
tests/pytests/integration/modules/test_state.py::test_logging_and_state_output_order
|
||||
tests/pytests/integration/modules/test_test.py::test_deprecation_warning_emits_deprecation_warnings
|
||||
tests/pytests/integration/renderers/test_jinja.py::test_issue_54765_call
|
||||
tests/pytests/integration/renderers/test_jinja.py::test_issue_54765_salt
|
||||
tests/pytests/integration/ssh/state/test_pillar_override_template.py::"test_it[args0-kwargs0]"
|
||||
tests/pytests/integration/ssh/state/test_pillar_override_template.py::"test_it[args1-kwargs1]"
|
||||
tests/pytests/integration/ssh/state/test_pillar_override_template.py::"test_it[args2-kwargs2]"
|
||||
tests/pytests/integration/ssh/state/test_retcode_highstate_verification_structure_fail.py::"test_it[args0-20]"
|
||||
tests/pytests/integration/ssh/state/test_retcode_highstate_verification_structure_fail.py::"test_it[args1-20]"
|
||||
tests/pytests/integration/ssh/state/test_retcode_highstate_verification_structure_fail.py::"test_it[args2-20]"
|
||||
tests/pytests/integration/ssh/state/test_retcode_highstate_verification_structure_fail.py::"test_it[args3-20]"
|
||||
tests/pytests/integration/ssh/state/test_retcode_highstate_verification_structure_fail.py::"test_it[args4-0]"
|
||||
tests/pytests/integration/ssh/state/test_retcode_highstate_verification_structure_fail.py::"test_it[args5-20]"
|
||||
tests/pytests/integration/ssh/test_jinja_filters.py::test_dateutils_strftime
|
||||
tests/pytests/integration/ssh/test_terraform.py::test_terraform_roster
|
||||
tests/pytests/unit/config/schemas/test_ssh.py::test_config_validate
|
||||
tests/pytests/unit/grains/test_core.py::test_get_machine_id
|
||||
tests/pytests/unit/grains/test_package.py::test_grain_package_type
|
||||
tests/pytests/unit/loader/test_loader.py::test_named_loader_context_name_not_packed
|
||||
tests/pytests/unit/modules/test_beacons.py::test_add
|
||||
tests/pytests/unit/modules/test_beacons.py::test_add_beacon_module
|
||||
tests/pytests/unit/modules/test_beacons.py::test_delete
|
||||
tests/pytests/unit/modules/test_beacons.py::test_delete_beacon_module
|
||||
tests/pytests/unit/modules/test_beacons.py::test_disable
|
||||
tests/pytests/unit/modules/test_beacons.py::test_enable
|
||||
tests/pytests/unit/modules/test_beacons.py::test_enable_beacon_module
|
||||
tests/pytests/unit/modules/test_beacons.py::test_save
|
||||
tests/pytests/unit/modules/test_gpg.py::test_create_key_with_passphrase_with_gpg_passphrase_in_pillar
|
||||
tests/pytests/unit/modules/test_gpg.py::test_create_key_without_passphrase
|
||||
tests/pytests/unit/modules/test_saltutil.py::test_clear_job_cache
|
||||
tests/pytests/unit/modules/test_saltutil.py::test_list_extmods
|
||||
tests/pytests/unit/pillar/test_pillar.py::test_pillar_get_cache_disk
|
||||
tests/pytests/unit/state/test_state_compiler.py::test_verify_high_too_many_functions_declared_error_message
|
||||
tests/pytests/unit/states/test_pkg.py::test_mod_beacon
|
||||
tests/pytests/unit/states/test_service.py::test_mod_beacon
|
||||
tests/pytests/unit/test_ext_importers.py::test_tornado_import_override
|
||||
tests/pytests/unit/utils/test_rsax931.py::test_find_libcrypto_darwin_catalina
|
||||
tests/pytests/unit/utils/test_versions.py::test_warn_until_good_version_argument
|
||||
tests/unit/transport/test_ipc.py::IPCMessagePubSubCase::test_async_reading_streamclosederror
|
||||
tests/unit/utils/test_thin.py::SSHThinTestCase::test_thin_dir
|
||||
tests/unit/utils/test_vt.py::VTTestCase::test_split_multibyte_characters_shiftjis
|
||||
tests/unit/utils/test_vt.py::VTTestCase::test_split_multibyte_characters_unicode
|
||||
tests/unit/utils/test_vt.py::VTTestCase::test_vt_size
|
||||
|
||||
# tests that need network access
|
||||
tests/pytests/functional/states/file/test_managed.py::test_verify_ssl_https_source
|
||||
tests/pytests/unit/modules/test_aptpkg.py::test_sourceslist_architectures
|
||||
tests/pytests/unit/modules/test_aptpkg.py::test_sourceslist_multiple_comps
|
||||
tests/pytests/unit/modules/test_yumpkg.py::test_get_yum_config
|
||||
tests/pytests/unit/modules/test_yumpkg.py::test_get_yum_config_value_none
|
||||
tests/pytests/unit/test_ext_importers.py::test_tornado_import_override
|
||||
tests/pytests/unit/utils/test_http.py::test_backends_decode_body_false
|
||||
tests/pytests/unit/utils/test_http.py::test_backends_decode_body_true
|
||||
tests/pytests/unit/utils/test_http.py::test_query_proxy
|
||||
tests/pytests/unit/utils/test_network.py::test_isportopen
|
||||
|
||||
# tests that need root access
|
||||
tests/unit/modules/test_saltcheck.py::SaltcheckTestCase::test_call_salt_command
|
||||
tests/unit/modules/test_saltcheck.py::SaltcheckTestCase::test_call_salt_command2
|
||||
tests/unit/modules/test_saltcheck.py::SaltcheckTestCase::test_run_test_1
|
||||
)
|
||||
[[ ${EPYTHON#*.} -ge 11 ]] && EPYTEST_DESELECT+=(
|
||||
tests/unit/test_master.py::TransportMethodsTest::test_aes_funcs_black
|
||||
tests/unit/test_master.py::TransportMethodsTest::test_clear_funcs_black
|
||||
)
|
||||
[[ ${EPYTHON#*.} -ge 12 ]] && EPYTEST_DESELECT+=(
|
||||
tests/integration/modules/test_mine.py::MineTest::test_get_allow_tgt
|
||||
tests/integration/modules/test_mine.py::MineTest::test_mine_delete
|
||||
tests/integration/modules/test_mine.py::MineTest::test_send_allow_tgt
|
||||
tests/integration/modules/test_mine.py::MineTest::test_send_allow_tgt_compound
|
||||
tests/integration/modules/test_saltcheck.py::SaltcheckModuleTest::test_saltcheck_checkall
|
||||
tests/integration/modules/test_saltcheck.py::SaltcheckModuleTest::test_saltcheck_checkall_saltenv
|
||||
tests/integration/modules/test_saltcheck.py::SaltcheckModuleTest::test_saltcheck_run
|
||||
tests/integration/modules/test_saltcheck.py::SaltcheckModuleTest::test_saltcheck_saltenv
|
||||
tests/integration/modules/test_saltcheck.py::SaltcheckModuleTest::test_saltcheck_state
|
||||
tests/integration/output/test_output.py::OutputReturnTest::test_output_highstate
|
||||
tests/integration/output/test_output.py::OutputReturnTest::test_output_json
|
||||
tests/integration/output/test_output.py::OutputReturnTest::test_output_nested
|
||||
tests/integration/output/test_output.py::OutputReturnTest::test_output_pprint
|
||||
tests/integration/output/test_output.py::OutputReturnTest::test_output_raw
|
||||
tests/integration/output/test_output.py::OutputReturnTest::test_output_txt
|
||||
tests/integration/output/test_output.py::OutputReturnTest::test_output_yaml
|
||||
tests/integration/output/test_output.py::OutputReturnTest::test_output_yaml_namespaced_dict_wrapper
|
||||
tests/integration/output/test_output.py::OutputReturnTest::test_static_simple
|
||||
tests/integration/runners/test_manage.py::ManageTest::test_down
|
||||
tests/integration/runners/test_manage.py::ManageTest::test_up
|
||||
tests/integration/shell/test_master_tops.py::MasterTopsTest::test_custom_tops_gets_utilized
|
||||
tests/integration/states/test_archive.py::ArchiveTest::test_local_archive_extracted_with_skip_files_list_verify_and_keep_source_is_false
|
||||
tests/pytests/functional/states/test_pip_state.py::test_issue_2087_missing_pip
|
||||
tests/pytests/unit/modules/test_nilrt_ip.py::"test_when_default_value_is_not_a_string_and_option_is_missing_the_default_value_should_be_returned[-99.9]"
|
||||
tests/pytests/unit/modules/test_nilrt_ip.py::"test_when_default_value_is_not_a_string_and_option_is_missing_the_default_value_should_be_returned[42]"
|
||||
tests/pytests/unit/modules/test_nilrt_ip.py::"test_when_default_value_is_not_a_string_and_option_is_missing_the_default_value_should_be_returned[default_value2]"
|
||||
tests/pytests/unit/modules/test_nilrt_ip.py::"test_when_default_value_is_not_a_string_and_option_is_missing_the_default_value_should_be_returned[default_value3]"
|
||||
tests/pytests/unit/modules/test_nilrt_ip.py::"test_when_default_value_is_not_a_string_and_option_is_missing_the_default_value_should_be_returned[default_value4]"
|
||||
tests/pytests/unit/modules/test_nilrt_ip.py::test_when_config_has_no_quotes_around_string_it_should_be_returned_as_is
|
||||
tests/pytests/unit/modules/test_nilrt_ip.py::test_when_config_has_quotes_around_string_they_should_be_removed
|
||||
tests/pytests/unit/utils/vault/test_auth.py::"test_approle_auth_get_token_login[secret_id-approle]"
|
||||
tests/unit/modules/test_zypperpkg.py::ZypperTestCase::test_repo_value_info
|
||||
tests/unit/utils/test_color.py::ColorUtilsTestCase::test_get_colors
|
||||
)
|
||||
|
||||
# testsuite likes lots of files
|
||||
ulimit -n 4096 || die
|
||||
|
||||
# ${T} is too long a path for the tests to work
|
||||
local TMPDIR
|
||||
TMPDIR="$(mktemp --directory --tmpdir=/tmp ${PN}-XXXX)" || die
|
||||
(
|
||||
test_exports=(
|
||||
TMPDIR
|
||||
SHELL="/bin/bash"
|
||||
USE_SETUPTOOLS=1
|
||||
NO_INTERNET=1
|
||||
PYTHONDONTWRITEBYTECODE=1
|
||||
)
|
||||
export "${test_exports[@]}"
|
||||
|
||||
cleanup() { rm -rf "${TMPDIR}" || die; }
|
||||
|
||||
trap cleanup EXIT
|
||||
|
||||
addwrite "${TMPDIR}"
|
||||
|
||||
epytest --run-slow
|
||||
)
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user