ansible-core 2.14.16rc1__py3-none-any.whl → 2.14.17rc1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of ansible-core might be problematic. Click here for more details.

ansible/galaxy/role.py CHANGED
@@ -387,6 +387,8 @@ class GalaxyRole(object):
387
387
  else:
388
388
  os.makedirs(self.path)
389
389
 
390
+ resolved_archive = unfrackpath(archive_parent_dir, follow=False)
391
+
390
392
  # We strip off any higher-level directories for all of the files
391
393
  # contained within the tar file here. The default is 'github_repo-target'.
392
394
  # Gerrit instances, on the other hand, does not have a parent directory at all.
@@ -401,33 +403,29 @@ class GalaxyRole(object):
401
403
  if not (attr_value := getattr(member, attr, None)):
402
404
  continue
403
405
 
404
- if attr_value.startswith(os.sep) and not is_subpath(attr_value, archive_parent_dir):
405
- err = f"Invalid {attr} for tarfile member: path {attr_value} is not a subpath of the role {archive_parent_dir}"
406
- raise AnsibleError(err)
407
-
408
406
  if attr == 'linkname':
409
407
  # Symlinks are relative to the link
410
- relative_to_archive_dir = os.path.dirname(getattr(member, 'name', ''))
411
- archive_dir_path = os.path.join(archive_parent_dir, relative_to_archive_dir, attr_value)
408
+ relative_to = os.path.dirname(getattr(member, 'name', ''))
412
409
  else:
413
410
  # Normalize paths that start with the archive dir
414
411
  attr_value = attr_value.replace(archive_parent_dir, "", 1)
415
412
  attr_value = os.path.join(*attr_value.split(os.sep)) # remove leading os.sep
416
- archive_dir_path = os.path.join(archive_parent_dir, attr_value)
413
+ relative_to = ''
417
414
 
418
- resolved_archive = unfrackpath(archive_parent_dir)
419
- resolved_path = unfrackpath(archive_dir_path)
420
- if not is_subpath(resolved_path, resolved_archive):
421
- err = f"Invalid {attr} for tarfile member: path {resolved_path} is not a subpath of the role {resolved_archive}"
415
+ full_path = os.path.join(resolved_archive, relative_to, attr_value)
416
+ if not is_subpath(full_path, resolved_archive, real=True):
417
+ err = f"Invalid {attr} for tarfile member: path {full_path} is not a subpath of the role {resolved_archive}"
422
418
  raise AnsibleError(err)
423
419
 
424
- relative_path = os.path.join(*resolved_path.replace(resolved_archive, "", 1).split(os.sep)) or '.'
420
+ relative_path_dir = os.path.join(resolved_archive, relative_to)
421
+ relative_path = os.path.join(*full_path.replace(relative_path_dir, "", 1).split(os.sep))
425
422
  setattr(member, attr, relative_path)
426
423
 
427
424
  if _check_working_data_filter():
428
425
  # deprecated: description='extract fallback without filter' python_version='3.11'
429
426
  role_tar_file.extract(member, to_native(self.path), filter='data') # type: ignore[call-arg]
430
427
  else:
428
+ # Remove along with manual path filter once Python 3.12 is minimum supported version
431
429
  role_tar_file.extract(member, to_native(self.path))
432
430
 
433
431
  # write out the install info file for later use
@@ -19,6 +19,6 @@
19
19
  from __future__ import (absolute_import, division, print_function)
20
20
  __metaclass__ = type
21
21
 
22
- __version__ = '2.14.16rc1'
22
+ __version__ = '2.14.17rc1'
23
23
  __author__ = 'Ansible, Inc.'
24
24
  __codename__ = "C'mon Everybody"
ansible/release.py CHANGED
@@ -19,6 +19,6 @@
19
19
  from __future__ import (absolute_import, division, print_function)
20
20
  __metaclass__ = type
21
21
 
22
- __version__ = '2.14.16rc1'
22
+ __version__ = '2.14.17rc1'
23
23
  __author__ = 'Ansible, Inc.'
24
24
  __codename__ = "C'mon Everybody"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ansible-core
3
- Version: 2.14.16rc1
3
+ Version: 2.14.17rc1
4
4
  Summary: Radically simple IT automation
5
5
  Home-page: https://ansible.com/
6
6
  Author: Ansible, Inc.
@@ -3,7 +3,7 @@ ansible/__main__.py,sha256=IvyRvY64pT0on94qCLibxgDJ0-7_2CRoaZ5kfGOl54Q,1395
3
3
  ansible/constants.py,sha256=JLIDnuSz3_PbtXWsL4vnvVBbxlh3lSrJREd7T73atEI,8293
4
4
  ansible/context.py,sha256=OzSlaA_GgGRyyf5I209sy19_eGOX6HXn441W9w_FcvU,2018
5
5
  ansible/keyword_desc.yml,sha256=FYY0Ld1Xc3AxJ_Tefz78kRSYzIKGS8qcPtVk370J118,7367
6
- ansible/release.py,sha256=XsJ3TvcEWkIl1LuDvF8pzyAxKoETH4r5R0eYSEZHTNQ,923
6
+ ansible/release.py,sha256=UW2Xnv2u1ovDvmo3Zzm631M0j9VdtU4D09a_S5N-MOo,923
7
7
  ansible/_vendor/__init__.py,sha256=wJRKH7kI9OzYVY9hgSchOsTNTmTnugpPLGYj9Y5akX0,2086
8
8
  ansible/cli/__init__.py,sha256=yDt8_ny7HauC9Aj-MMHQr3Y6gDQADfdEU0O1BfzkSwA,27957
9
9
  ansible/cli/adhoc.py,sha256=pGW6eysaireovp4sVsUuntg-l1o7DSujuhxVhVC2zsM,8230
@@ -56,7 +56,7 @@ ansible/executor/process/__init__.py,sha256=1lMXN1i2fFqslda4BmeI5tpYMFP95D5Wpr1A
56
56
  ansible/executor/process/worker.py,sha256=mO9-GR7bDVxgDh65ROBhEBNg8qb9FWkkaP1vb_sklxY,8843
57
57
  ansible/galaxy/__init__.py,sha256=_ccTedn8dUGGtkmHcQLIkeje_YD0TYSXlvCl1AOY5fE,2533
58
58
  ansible/galaxy/api.py,sha256=deSYsFinaJodT2Y9-XnOerWIwYY8V2AWQ_9kZI0pWCE,39872
59
- ansible/galaxy/role.py,sha256=g7vPiT4IWpsXHP3Z5g9L4Y0lxfRbrRXixewAIN-XgRk,21379
59
+ ansible/galaxy/role.py,sha256=uc0PCEZD0Nm7-SCiMgKI7wfrmLwD25R8T3s0tBAnua4,21104
60
60
  ansible/galaxy/token.py,sha256=K0dAwD3Fjkn3Zs2N9sG98UesSWfAukie47QGyYpIf0M,6167
61
61
  ansible/galaxy/user_agent.py,sha256=x7cJzzpnTngHcwqSUd2hg0i28Dv0tbAyBdke5CSiNhM,813
62
62
  ansible/galaxy/collection/__init__.py,sha256=GnhmFRCktOQK3p6lFr-pupxeEMOG09HPJLujyruIx-I,75744
@@ -139,7 +139,7 @@ ansible/inventory/host.py,sha256=wXJp6kpSaZtDr4JNsgdAuhi5MzQ9LTQzaAH10zoVbIA,505
139
139
  ansible/inventory/manager.py,sha256=tGwhBR6poLuG_i4jZ5RGOG-rH4gu4DBfT0-4iLLZZMs,29490
140
140
  ansible/module_utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
141
141
  ansible/module_utils/_text.py,sha256=VCjTJovTxGfLahnzyrvOehpwTXLpRzMUug6wheirt4A,565
142
- ansible/module_utils/ansible_release.py,sha256=XsJ3TvcEWkIl1LuDvF8pzyAxKoETH4r5R0eYSEZHTNQ,923
142
+ ansible/module_utils/ansible_release.py,sha256=UW2Xnv2u1ovDvmo3Zzm631M0j9VdtU4D09a_S5N-MOo,923
143
143
  ansible/module_utils/api.py,sha256=BTo7stVOANbtd-ngZslaqx70r9t5gfvo44cKyu5SFjU,5837
144
144
  ansible/module_utils/basic.py,sha256=dGTJD-84x2a0hqKgoqB6PNhjmOEqYuuf2EgWyX5zVC8,86621
145
145
  ansible/module_utils/connection.py,sha256=XHxMlyAdwLiXDSo8jBMkV61-lz_0FDJUYH1B152UGJU,8430
@@ -674,7 +674,7 @@ ansible/vars/hostvars.py,sha256=dg3jpVmNwSg8EJ4SIvYGT80uxMgRtrOW6vvtDfrQzDU,5152
674
674
  ansible/vars/manager.py,sha256=9d-9uD9x1X35QgLOZRyJtAxg3b1j4sp8Ivc5C78viOk,36178
675
675
  ansible/vars/plugins.py,sha256=B7L3fXoSOoBZSXqJ2ulk0adx1g5SpAb8BxyLGPNA7d4,4695
676
676
  ansible/vars/reserved.py,sha256=FBD7n2dnA0CW4I0J1LtWwk2hQqvGW0KTRPcxaRtMKWo,2615
677
- ansible_core-2.14.16rc1.data/scripts/ansible-test,sha256=CYIYL99IxWdVTtDIj3avilIJXhGAmtjuKPPWNuLWuc8,1690
677
+ ansible_core-2.14.17rc1.data/scripts/ansible-test,sha256=CYIYL99IxWdVTtDIj3avilIJXhGAmtjuKPPWNuLWuc8,1690
678
678
  ansible_test/__init__.py,sha256=6e721yAyyyocRKzbCKtQXloAfFP7Aqv0L3zG70uh-4A,190
679
679
  ansible_test/_data/ansible.cfg,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
680
680
  ansible_test/_data/coveragerc,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -756,7 +756,7 @@ ansible_test/_internal/locale_util.py,sha256=tjRbwKmgMQc1ysIhvP8yBhFcNA-2UCaWfQB
756
756
  ansible_test/_internal/metadata.py,sha256=c9ThXPUlgeKYhaTUmfCSS4INRNQ1JhN2KEOVaX3m1Gk,4791
757
757
  ansible_test/_internal/payload.py,sha256=1Pw05OEHvP3LMQnoLXch8631c94YMklWlpDn0CvQECw,8012
758
758
  ansible_test/_internal/provisioning.py,sha256=9Zl3xQqljx0MGDTp55Q4LZPWQ7Afj5K87cGsXzPGS5Y,7320
759
- ansible_test/_internal/pypi_proxy.py,sha256=kVvqvLIxN-VolD1jG_EILwYy1bWoy766ZKVKEFlQgmA,6040
759
+ ansible_test/_internal/pypi_proxy.py,sha256=b0UQjxOkI7pZUBrrR6tfhGWta9NvI4qlF7UUADoq7us,6224
760
760
  ansible_test/_internal/python_requirements.py,sha256=T5FIlohIFeHHcFAJcsL8bUSvgQ-xg_JUyEZJaZL2PFg,20401
761
761
  ansible_test/_internal/ssh.py,sha256=2bS-DkcMJcBr3NExF2Y_htJVye_glKXir1NmLF05VR8,10662
762
762
  ansible_test/_internal/target.py,sha256=Whtb_n0jn4zbiMmX7je5jewgzsRczfXRm_ndYtjTSTQ,25320
@@ -992,9 +992,9 @@ ansible_test/config/cloud-config-vultr.ini.template,sha256=yO2Xz76Ay3kbG54jX7y8-
992
992
  ansible_test/config/config.yml,sha256=wb3knoBmZewG3GWOMnRHoVPQWW4vPixKLPMNS6vJmTc,2620
993
993
  ansible_test/config/inventory.networking.template,sha256=vQ7x1-u5Q4Y5CqZU-7eMSEJOSCzAbPOL1rmK_AQOQuY,1262
994
994
  ansible_test/config/inventory.winrm.template,sha256=_M2i1B9RYfwSjwvgf3M-H_5Br5FO_kney_kMRPmoggk,1025
995
- ansible_core-2.14.16rc1.dist-info/COPYING,sha256=CuBIWlvTemPmNgNZZBfk6w5lMzT6bH-TLKOg6F1K8ic,35148
996
- ansible_core-2.14.16rc1.dist-info/METADATA,sha256=xRIASk8OoHyGR8ET8vdgt7kVpVRnZqBO8RwZWnzgkwE,6907
997
- ansible_core-2.14.16rc1.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
998
- ansible_core-2.14.16rc1.dist-info/entry_points.txt,sha256=0mpmsrIhODChxKl3eS-NcVQCaMetBn8KdPLtVxQgR64,453
999
- ansible_core-2.14.16rc1.dist-info/top_level.txt,sha256=IFbRLjAvih1DYzJWg3_F6t4sCzEMxRO7TOMNs6GkYHo,21
1000
- ansible_core-2.14.16rc1.dist-info/RECORD,,
995
+ ansible_core-2.14.17rc1.dist-info/COPYING,sha256=CuBIWlvTemPmNgNZZBfk6w5lMzT6bH-TLKOg6F1K8ic,35148
996
+ ansible_core-2.14.17rc1.dist-info/METADATA,sha256=ZBqKIdWQXiQ6a7ar1jOIJslUzK-lJdDHLjqBIsdJey4,6907
997
+ ansible_core-2.14.17rc1.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
998
+ ansible_core-2.14.17rc1.dist-info/entry_points.txt,sha256=0mpmsrIhODChxKl3eS-NcVQCaMetBn8KdPLtVxQgR64,453
999
+ ansible_core-2.14.17rc1.dist-info/top_level.txt,sha256=IFbRLjAvih1DYzJWg3_F6t4sCzEMxRO7TOMNs6GkYHo,21
1000
+ ansible_core-2.14.17rc1.dist-info/RECORD,,
@@ -14,6 +14,7 @@ from .config import (
14
14
 
15
15
  from .host_configs import (
16
16
  PosixConfig,
17
+ DockerConfig,
17
18
  )
18
19
 
19
20
  from .util import (
@@ -55,8 +56,14 @@ def run_pypi_proxy(args: EnvironmentConfig, targets_use_pypi: bool) -> None:
55
56
  return # user has overridden the proxy endpoint, there is nothing to provision
56
57
 
57
58
  versions_needing_proxy: tuple[str, ...] = tuple() # preserved for future use, no versions currently require this
59
+ containers_needing_proxy: set[str] = {'centos7'}
58
60
  posix_targets = [target for target in args.targets if isinstance(target, PosixConfig)]
59
- need_proxy = targets_use_pypi and any(target.python.version in versions_needing_proxy for target in posix_targets)
61
+ need_proxy = targets_use_pypi and any(
62
+ target.python.version in versions_needing_proxy or
63
+ (isinstance(target, DockerConfig) and target.name in containers_needing_proxy)
64
+ for target in posix_targets
65
+ )
66
+
60
67
  use_proxy = args.pypi_proxy or need_proxy
61
68
 
62
69
  if not use_proxy: