ansible-core 2.14.17__py3-none-any.whl → 2.14.18rc1__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.

@@ -645,8 +645,8 @@ class TaskExecutor:
645
645
  self._handler.cleanup()
646
646
  display.debug("handler run complete")
647
647
 
648
- # preserve no log
649
- result["_ansible_no_log"] = no_log
648
+ # propagate no log to result- the action can set this, so only overwrite it with the task's value if missing or falsey
649
+ result["_ansible_no_log"] = bool(no_log or result.get('_ansible_no_log', False))
650
650
 
651
651
  if self._task.action not in C._ACTION_WITH_CLEAN_FACTS:
652
652
  result = wrap_var(result)
@@ -19,6 +19,6 @@
19
19
  from __future__ import (absolute_import, division, print_function)
20
20
  __metaclass__ = type
21
21
 
22
- __version__ = '2.14.17'
22
+ __version__ = '2.14.18rc1'
23
23
  __author__ = 'Ansible, Inc.'
24
24
  __codename__ = "C'mon Everybody"
ansible/modules/user.py CHANGED
@@ -1152,9 +1152,11 @@ class User(object):
1152
1152
  overwrite = None
1153
1153
  try:
1154
1154
  ssh_key_file = self.get_ssh_key_path()
1155
+ pub_file = '%s.pub' % ssh_key_file
1155
1156
  except Exception as e:
1156
1157
  return (1, '', to_native(e))
1157
1158
  ssh_dir = os.path.dirname(ssh_key_file)
1159
+
1158
1160
  if not os.path.exists(ssh_dir):
1159
1161
  if self.module.check_mode:
1160
1162
  return (0, '', '')
@@ -1163,12 +1165,23 @@ class User(object):
1163
1165
  os.chown(ssh_dir, info[2], info[3])
1164
1166
  except OSError as e:
1165
1167
  return (1, '', 'Failed to create %s: %s' % (ssh_dir, to_native(e)))
1168
+
1166
1169
  if os.path.exists(ssh_key_file):
1167
1170
  if self.force:
1168
- # ssh-keygen doesn't support overwriting the key interactively, so send 'y' to confirm
1171
+ self.module.warn('Overwriting existing ssh key private file "%s"' % ssh_key_file)
1169
1172
  overwrite = 'y'
1170
1173
  else:
1174
+ self.module.warn('Found existing ssh key private file "%s", no force, so skipping ssh-keygen generation' % ssh_key_file)
1171
1175
  return (None, 'Key already exists, use "force: yes" to overwrite', '')
1176
+
1177
+ if os.path.exists(pub_file):
1178
+ if self.force:
1179
+ self.module.warn('Overwriting existing ssh key public file "%s"' % pub_file)
1180
+ os.unlink(pub_file)
1181
+ else:
1182
+ self.module.warn('Found existing ssh key public file "%s", no force, so skipping ssh-keygen generation' % pub_file)
1183
+ return (None, 'Public key already exists, use "force: yes" to overwrite', '')
1184
+
1172
1185
  cmd = [self.module.get_bin_path('ssh-keygen', True)]
1173
1186
  cmd.append('-t')
1174
1187
  cmd.append(self.ssh_type)
@@ -1235,7 +1248,7 @@ class User(object):
1235
1248
  # If the keys were successfully created, we should be able
1236
1249
  # to tweak ownership.
1237
1250
  os.chown(ssh_key_file, info[2], info[3])
1238
- os.chown('%s.pub' % ssh_key_file, info[2], info[3])
1251
+ os.chown(pub_file, info[2], info[3])
1239
1252
  return (rc, out, err)
1240
1253
 
1241
1254
  def ssh_key_fingerprint(self):
@@ -237,7 +237,8 @@ class ActionModule(ActionBase):
237
237
  b_data, show_content = self._loader._get_file_contents(filename)
238
238
  data = to_text(b_data, errors='surrogate_or_strict')
239
239
 
240
- self.show_content = show_content
240
+ self.show_content &= show_content # mask all results if any file was encrypted
241
+
241
242
  data = self._loader.load(data, file_name=filename, show_content=show_content)
242
243
  if not data:
243
244
  data = dict()
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.17'
22
+ __version__ = '2.14.18rc1'
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.17
3
+ Version: 2.14.18rc1
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=r-3oeN3YfpkGvNsozE_LUu_6-TDnhA9VEvvNPDtN6Vc,920
6
+ ansible/release.py,sha256=9TRrWe_O2UO2iC93GJnzi3R6tNPyekMVhayXOEUy2zc,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
@@ -36,7 +36,7 @@ ansible/executor/module_common.py,sha256=6R58IqfOLzg0aDQWRWsi0cbohWMSf_Lvdhf_5hT
36
36
  ansible/executor/play_iterator.py,sha256=FUxYjkFU8s9RessNxdey66TWfXP1NvWXZbzBDFAJYdY,31013
37
37
  ansible/executor/playbook_executor.py,sha256=TXFPpitH9mz1AFNMZxwwI5Zu6PQp7uFkl5v5MNThCd0,15075
38
38
  ansible/executor/stats.py,sha256=757UK8wDzLCXq4ltI9PqpoMNAdtRsd9D9-GS-5Al_Hs,3264
39
- ansible/executor/task_executor.py,sha256=bL-s8uo6GqxdqqxXptHqGzeKq0UNLCkrKTY6YQOiqaY,58343
39
+ ansible/executor/task_executor.py,sha256=K4A3QHqlwz1I95uswZoW_HHgXTEhWVgLHbH0ZSiPH3U,58490
40
40
  ansible/executor/task_queue_manager.py,sha256=vR66r6E8DHOpfwLAVeHI3UusGZyDUZtmrwHNoYRLvvs,18375
41
41
  ansible/executor/task_result.py,sha256=DvshMci5i9-qCXs0m_vScSa6BJMbPwwNQBV7L2DTCzE,5748
42
42
  ansible/executor/discovery/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -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=r-3oeN3YfpkGvNsozE_LUu_6-TDnhA9VEvvNPDtN6Vc,920
142
+ ansible/module_utils/ansible_release.py,sha256=9TRrWe_O2UO2iC93GJnzi3R6tNPyekMVhayXOEUy2zc,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
@@ -339,7 +339,7 @@ ansible/modules/tempfile.py,sha256=D4l0CHjp9AIC0o1BBDvw8UWQkWpilnc9VdmxNChxq6E,3
339
339
  ansible/modules/template.py,sha256=k0h7j9n9v2efC0f1boCsTq2NwgTLkFuQxgxmUgq4nZE,3171
340
340
  ansible/modules/unarchive.py,sha256=77kv3buZezvXMb-8KmFvV-rtiyVdcvynaOw84bzk2Js,43815
341
341
  ansible/modules/uri.py,sha256=2jWiuBln8378jQuL1CLH-BCNg1ZaO27rMw5LW1TLVQg,28451
342
- ansible/modules/user.py,sha256=qOnO_lxilSM--HAuO7UtC5g8PKaMS8hiD7QNpnTbyrY,116313
342
+ ansible/modules/user.py,sha256=clIRXEpiCyTE1lAIMKuUncQIOJr_PRkyuhw0ztzgock,116918
343
343
  ansible/modules/validate_argument_spec.py,sha256=O0IJWWX7L-i87OrFRjNzG0Tpz-0rHKBKi_zFPd9EOv4,3066
344
344
  ansible/modules/wait_for.py,sha256=8xLXpbwlXiL4Wwan0cQgpHoQaB6xaqn9Oc5TM4W9Xis,26530
345
345
  ansible/modules/wait_for_connection.py,sha256=YKLM15BMeJxi7ev0h5bRxo5DVWK9yKV_6xaP2LyUfvY,3461
@@ -400,7 +400,7 @@ ansible/plugins/action/fail.py,sha256=tzfT2C4Qn0ifPyl8X3HfPXImTmSsp1DtpvHbojjwdO
400
400
  ansible/plugins/action/fetch.py,sha256=17H2Nlqf4DRDTAVE1jbhc0oLSzFK_oy06L9pN0k_oKU,9869
401
401
  ansible/plugins/action/gather_facts.py,sha256=UaHiZx4WMNJJ_gvs81r72mccFXFSeXL9O7DBoUdEFz8,6709
402
402
  ansible/plugins/action/group_by.py,sha256=bjgpc3YhM3B8BXPxzABHZU_qeb5vEVptFicuzJJnDxI,1914
403
- ansible/plugins/action/include_vars.py,sha256=cOzuJmQF_LvSuKXeZM4faflcO-twk2GwdZurx196McE,11414
403
+ ansible/plugins/action/include_vars.py,sha256=qveEz2kxA46-keefomYVVxlIWhjBoHcw9Zy47Pb1H5Q,11462
404
404
  ansible/plugins/action/normal.py,sha256=7FqFctSJtY1wcojFc-jCOq8oVFCc2P62zW8HQcmLRZY,2449
405
405
  ansible/plugins/action/package.py,sha256=iam5kUcjiiB2YSFaFjCXOj9VAw6Dj9yIdb_MlEOGojk,4224
406
406
  ansible/plugins/action/pause.py,sha256=dWqYmBSWcKPY1DJZ2Sa6o65GopzoF5RuY4EftGmGJJQ,11578
@@ -674,14 +674,14 @@ 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.17.data/scripts/ansible-test,sha256=CYIYL99IxWdVTtDIj3avilIJXhGAmtjuKPPWNuLWuc8,1690
677
+ ansible_core-2.14.18rc1.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
681
681
  ansible_test/_data/completion/docker.txt,sha256=q47NhD2sEadcFZ_eOi33MqUh_nJNUsnyUmCnkszIhuM,822
682
- ansible_test/_data/completion/network.txt,sha256=_-mi013-JeufshKMUmykkOmZPw1cVbakIMaAuweHet8,198
682
+ ansible_test/_data/completion/network.txt,sha256=BxVN0UxlVkRUrPi9MBArQOe6nR8exaow0oCAznUdfKQ,100
683
683
  ansible_test/_data/completion/remote.txt,sha256=NmxcuGAfR0oH2ON8DOnKpXikaflJVe2WFTJR-t5e2Zw,954
684
- ansible_test/_data/completion/windows.txt,sha256=7xcstRugKOY6lnvJd1nzLE7I5awR-uQfmPtRoyPAg7g,230
684
+ ansible_test/_data/completion/windows.txt,sha256=LunFLE7xMeoS9TVDuE58nUBVzsz-Wh-9wfL80mGiUmo,147
685
685
  ansible_test/_data/playbooks/posix_coverage_setup.yml,sha256=PgQNVzVTsNmfnu0sT2SAYiWtkMSOppfmh0oVmAsb7TQ,594
686
686
  ansible_test/_data/playbooks/posix_coverage_teardown.yml,sha256=xHci5QllwJymFtig-hsOXm-Wdrxz063JH14aIyRXhyc,212
687
687
  ansible_test/_data/playbooks/posix_hosts_prepare.yml,sha256=B_nfyUJMB3BkanlltW4oXCVna7IeEw86FZ1q28kRmhM,245
@@ -741,7 +741,7 @@ ansible_test/_internal/coverage_util.py,sha256=iw45rwz8Q5u37S4_dABNR0-Ybc5F8YRiE
741
741
  ansible_test/_internal/data.py,sha256=OFDpRa47yqBqQO1aSvTZVQQpScHvBHsr861586MQEUI,11184
742
742
  ansible_test/_internal/delegation.py,sha256=xw9pjUmdGLT-xz5LdcH4s4EMDFHrMrZeMv60Rkj7iDc,13458
743
743
  ansible_test/_internal/diff.py,sha256=COo6OgC3zxwymhOTlMifLZsGc1RGL0iM_zFVyqFNK48,7300
744
- ansible_test/_internal/docker_util.py,sha256=LF4RrClcsDhg3UqrqgOztbeB_oWcsf1nc3W4DFacans,37675
744
+ ansible_test/_internal/docker_util.py,sha256=tlHeB7-fCYYdFpkJJVdi4DON8SSc2Ezt9TfD163Ljls,37994
745
745
  ansible_test/_internal/encoding.py,sha256=E61EfXbQw0uQoFhbN3SYx3Oy_1tAMCPAAvY9hkEcSSo,1367
746
746
  ansible_test/_internal/executor.py,sha256=KW5yI-f-giErQ077MTj707fTtFkf_Kr8IV_Nr36NNmc,2959
747
747
  ansible_test/_internal/git.py,sha256=njtciWq2DlzZ1DAkQi08HRRP-TgH0mgeGZsWcsJGctI,4366
@@ -756,14 +756,14 @@ 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=b0UQjxOkI7pZUBrrR6tfhGWta9NvI4qlF7UUADoq7us,6224
759
+ ansible_test/_internal/pypi_proxy.py,sha256=nfqZJ7-SGBFrYV7WRrVsGIbe1fV8dSwTvZfY3x1L7Rk,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
763
763
  ansible_test/_internal/test.py,sha256=znQmGjKACqDU8T0EAPqcv2qyy0J7M2w4OmyYhwHLqT0,14515
764
764
  ansible_test/_internal/thread.py,sha256=WQoZ2q2ljmEkKHRDkIqwxW7eZbkCKDrG3YZfcaxHzHw,2596
765
765
  ansible_test/_internal/timeout.py,sha256=hT-LirImhAh1iCGIh8JpmECXsiGu6Zetw8BWl1iBIC8,4050
766
- ansible_test/_internal/util.py,sha256=KRb3EtwZ6_99cgIx36DqOlm5lvCC4ZrEq-OzQfSNt4A,37687
766
+ ansible_test/_internal/util.py,sha256=-x3TRkILkuZhf2tOwi43E_vl9vqsOKtzsm-tnbK7AUg,37912
767
767
  ansible_test/_internal/util_common.py,sha256=JvKuI4Z_iTfBIA22zDFUgPWUuPbx64sbV6ACpKx5l3w,17281
768
768
  ansible_test/_internal/venv.py,sha256=DPHAt4tuoIdP7BOXa75-i4T7Paild8eGDsV2UUKOZ7U,9062
769
769
  ansible_test/_internal/ci/__init__.py,sha256=QOaC_8_wUzqFEbsFCXYAnElWoUo6gB40CXvP9RJ-Iyo,7738
@@ -971,7 +971,7 @@ ansible_test/_util/target/pytest/plugins/ansible_pytest_coverage.py,sha256=Nr52Y
971
971
  ansible_test/_util/target/sanity/compile/compile.py,sha256=X1WHH2iLT4K8kyYJKlr-6AL6EAzKisL_hYrjvGrHCZ8,1637
972
972
  ansible_test/_util/target/sanity/import/importer.py,sha256=Q2cmqi-dFOfXYFzPybbWKgqMYUnjmXz7WFiYb9ysEO4,26208
973
973
  ansible_test/_util/target/setup/ConfigureRemotingForAnsible.ps1,sha256=pW9YaaSNvhc_0ijjMfSMdoQkrmZNJ-Rb4xCL8m8t7yU,16693
974
- ansible_test/_util/target/setup/bootstrap.sh,sha256=jhGgVHU5WZ7apNmhutW7_LIFK-_aUG9MQmIs5rHamWw,13295
974
+ ansible_test/_util/target/setup/bootstrap.sh,sha256=RusK4-Mrfv48HCb4daH00Z4ikWKrbGGdVusjtz0H82A,13657
975
975
  ansible_test/_util/target/setup/check_systemd_cgroup_v1.sh,sha256=Aq0T62x_KLtkGaWzYqWjvhchTqYFflrTbQET3h6xrT0,395
976
976
  ansible_test/_util/target/setup/probe_cgroups.py,sha256=ygqTkZc_YDH6EkZqp95rk_xkqsYcy_9IslPHKZO2A-8,712
977
977
  ansible_test/_util/target/setup/quiet_pip.py,sha256=k-EK8Ny7AcekGTejRFq0oV4YTVHaYUVpjfRLbKVApnc,3267
@@ -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.17.dist-info/COPYING,sha256=CuBIWlvTemPmNgNZZBfk6w5lMzT6bH-TLKOg6F1K8ic,35148
996
- ansible_core-2.14.17.dist-info/METADATA,sha256=_uiedPskkBKirL7hVb0MJhwVhEWpWRcNWHQ7RusldHs,6904
997
- ansible_core-2.14.17.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
998
- ansible_core-2.14.17.dist-info/entry_points.txt,sha256=0mpmsrIhODChxKl3eS-NcVQCaMetBn8KdPLtVxQgR64,453
999
- ansible_core-2.14.17.dist-info/top_level.txt,sha256=IFbRLjAvih1DYzJWg3_F6t4sCzEMxRO7TOMNs6GkYHo,21
1000
- ansible_core-2.14.17.dist-info/RECORD,,
995
+ ansible_core-2.14.18rc1.dist-info/COPYING,sha256=CuBIWlvTemPmNgNZZBfk6w5lMzT6bH-TLKOg6F1K8ic,35148
996
+ ansible_core-2.14.18rc1.dist-info/METADATA,sha256=6okdlCp9I3bKg9VDnxeRQQEvyniKthXwlOVmcBEtLzY,6907
997
+ ansible_core-2.14.18rc1.dist-info/WHEEL,sha256=P9jw-gEje8ByB7_hXoICnHtVCrEwMQh-630tKvQWehc,91
998
+ ansible_core-2.14.18rc1.dist-info/entry_points.txt,sha256=0mpmsrIhODChxKl3eS-NcVQCaMetBn8KdPLtVxQgR64,453
999
+ ansible_core-2.14.18rc1.dist-info/top_level.txt,sha256=IFbRLjAvih1DYzJWg3_F6t4sCzEMxRO7TOMNs6GkYHo,21
1000
+ ansible_core-2.14.18rc1.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: bdist_wheel (0.43.0)
2
+ Generator: setuptools (75.3.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
@@ -1,2 +1 @@
1
1
  ios/csr1000v collection=cisco.ios connection=ansible.netcommon.network_cli provider=aws arch=x86_64
2
- vyos/1.1.8 collection=vyos.vyos connection=ansible.netcommon.network_cli provider=aws arch=x86_64
@@ -1,5 +1,3 @@
1
- windows/2012 provider=azure arch=x86_64
2
- windows/2012-R2 provider=azure arch=x86_64
3
1
  windows/2016 provider=aws arch=x86_64
4
2
  windows/2019 provider=aws arch=x86_64
5
3
  windows/2022 provider=aws arch=x86_64
@@ -20,6 +20,8 @@ from .util import (
20
20
  SubprocessError,
21
21
  cache,
22
22
  OutputStream,
23
+ InternalError,
24
+ format_command_output,
23
25
  )
24
26
 
25
27
  from .util_common import (
@@ -300,7 +302,7 @@ def detect_host_properties(args: CommonConfig) -> ContainerHostProperties:
300
302
  options = ['--volume', '/sys/fs/cgroup:/probe:ro']
301
303
  cmd = ['sh', '-c', ' && echo "-" && '.join(multi_line_commands)]
302
304
 
303
- stdout = run_utility_container(args, f'ansible-test-probe-{args.session_name}', cmd, options)[0]
305
+ stdout, stderr = run_utility_container(args, f'ansible-test-probe-{args.session_name}', cmd, options)
304
306
 
305
307
  if args.explain:
306
308
  return ContainerHostProperties(
@@ -313,6 +315,12 @@ def detect_host_properties(args: CommonConfig) -> ContainerHostProperties:
313
315
 
314
316
  blocks = stdout.split('\n-\n')
315
317
 
318
+ if len(blocks) != len(multi_line_commands):
319
+ message = f'Unexpected probe output. Expected {len(multi_line_commands)} blocks but found {len(blocks)}.\n'
320
+ message += format_command_output(stdout, stderr)
321
+
322
+ raise InternalError(message.strip())
323
+
316
324
  values = blocks[0].split('\n')
317
325
 
318
326
  audit_parts = values[0].split(' ', 1)
@@ -76,7 +76,7 @@ def run_pypi_proxy(args: EnvironmentConfig, targets_use_pypi: bool) -> None:
76
76
  display.warning('Unable to use the PyPI proxy because Docker is not available. Installation of packages using `pip` may fail.')
77
77
  return
78
78
 
79
- image = 'quay.io/ansible/pypi-test-container:2.0.0'
79
+ image = 'quay.io/ansible/pypi-test-container:3.1.0'
80
80
  port = 3141
81
81
 
82
82
  run_support_container(
@@ -935,14 +935,7 @@ class SubprocessError(ApplicationError):
935
935
  error_callback: t.Optional[c.Callable[[SubprocessError], None]] = None,
936
936
  ) -> None:
937
937
  message = 'Command "%s" returned exit status %s.\n' % (shlex.join(cmd), status)
938
-
939
- if stderr:
940
- message += '>>> Standard Error\n'
941
- message += '%s%s\n' % (stderr.strip(), Display.clear)
942
-
943
- if stdout:
944
- message += '>>> Standard Output\n'
945
- message += '%s%s\n' % (stdout.strip(), Display.clear)
938
+ message += format_command_output(stdout, stderr)
946
939
 
947
940
  self.cmd = cmd
948
941
  self.message = message
@@ -986,6 +979,21 @@ class HostConnectionError(ApplicationError):
986
979
  self._callback()
987
980
 
988
981
 
982
+ def format_command_output(stdout: str, stderr: str) -> str:
983
+ """Return a formatted string containing the given stdout and stderr (if any)."""
984
+ message = ''
985
+
986
+ if stderr := stderr.strip():
987
+ message += '>>> Standard Error\n'
988
+ message += f'{stderr}{Display.clear}\n'
989
+
990
+ if stdout := stdout.strip():
991
+ message += '>>> Standard Output\n'
992
+ message += f'{stdout}{Display.clear}\n'
993
+
994
+ return message
995
+
996
+
989
997
  def retry(func: t.Callable[..., TValue], ex_type: t.Type[BaseException] = SubprocessError, sleep: int = 10, attempts: int = 10, warn: bool = True) -> TValue:
990
998
  """Retry the specified function on failure."""
991
999
  for dummy in range(1, attempts):
@@ -410,6 +410,15 @@ bootstrap_docker()
410
410
  {
411
411
  # Required for newer mysql-server packages to install/upgrade on Ubuntu 16.04.
412
412
  rm -f /usr/sbin/policy-rc.d
413
+
414
+ # CentOS 7 is EoL and its official repos are down; we need to the archived ones.
415
+ if grep -q '^CENTOS_MANTISBT_PROJECT="CentOS-7"$' /etc/os-release
416
+ then
417
+ sed -i \
418
+ -e 's/mirrorlist/#mirrorlist/g' \
419
+ -e 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' \
420
+ /etc/yum.repos.d/CentOS-*
421
+ fi
413
422
  }
414
423
 
415
424
  bootstrap_remote()