|
| 1 | + |
| 2 | +.. _porting_2.18_guide_core: |
| 3 | + |
| 4 | +******************************* |
| 5 | +Ansible-core 2.18 Porting Guide |
| 6 | +******************************* |
| 7 | + |
| 8 | +This section discusses the behavioral changes between ``ansible-core`` 2.17 and ``ansible-core`` 2.18. |
| 9 | + |
| 10 | +It is intended to assist in updating your playbooks, plugins and other parts of your Ansible infrastructure so they will work with this version of Ansible. |
| 11 | + |
| 12 | +We suggest you read this page along with `ansible-core Changelog for 2.18 <https://github.com/ansible/ansible/blob/stable-2.18/changelogs/CHANGELOG-v2.18.rst>`_ to understand what updates you may need to make. |
| 13 | + |
| 14 | +This document is part of a collection on porting. The complete list of porting guides can be found at :ref:`porting guides <porting_guides>`. |
| 15 | + |
| 16 | +.. contents:: Topics |
| 17 | + |
| 18 | + |
| 19 | +Playbook |
| 20 | +======== |
| 21 | + |
| 22 | +No notable changed |
| 23 | + |
| 24 | + |
| 25 | +Command Line |
| 26 | +============ |
| 27 | + |
| 28 | +* Python 3.10 is a no longer supported control node version. Python 3.11+ is now required for running Ansible. |
| 29 | +* Python 3.7 is a no longer supported remote version. Python 3.8+ is now required for target execution. |
| 30 | + |
| 31 | + |
| 32 | +Deprecated |
| 33 | +========== |
| 34 | + |
| 35 | +No notable changes |
| 36 | + |
| 37 | + |
| 38 | +Modules |
| 39 | +======= |
| 40 | + |
| 41 | +No notable changes |
| 42 | + |
| 43 | + |
| 44 | +Modules removed |
| 45 | +--------------- |
| 46 | + |
| 47 | +The following modules no longer exist: |
| 48 | + |
| 49 | +* No notable changes |
| 50 | + |
| 51 | + |
| 52 | +Deprecation notices |
| 53 | +------------------- |
| 54 | + |
| 55 | +No notable changes |
| 56 | + |
| 57 | + |
| 58 | +Noteworthy module changes |
| 59 | +------------------------- |
| 60 | + |
| 61 | +No notable changes |
| 62 | + |
| 63 | + |
| 64 | +Plugins |
| 65 | +======= |
| 66 | + |
| 67 | +* The ``ssh`` connection plugin now officially supports targeting Windows hosts. A |
| 68 | + breaking change that has been made as part of this official support is the low level command |
| 69 | + execution done by plugins like ``ansible.builtin.raw`` and action plugins calling |
| 70 | + ``_low_level_execute_command`` is no longer wrapped with a ``powershell.exe`` wrapped |
| 71 | + invocation. These commands will now be executed directly on the target host using |
| 72 | + the default shell configuration set on the Windows host. This change is done to |
| 73 | + simplify the configuration required on the Ansible side, make module execution more |
| 74 | + efficient, and to remove the need to decode stderr CLIXML output. A consequence of this |
| 75 | + change is that ``ansible.builtin.raw`` commands are no longer guaranteed to be |
| 76 | + run through a PowerShell shell and with the output encoding of UTF-8. To run a command |
| 77 | + through PowerShell and with UTF-8 output support, use the ``ansible.windows.win_shell`` |
| 78 | + or ``ansible.windows.win_powershell`` module instead. |
| 79 | + |
| 80 | + .. code-block:: yaml |
| 81 | +
|
| 82 | + - name: Run with win_shell |
| 83 | + ansible.windows.win_shell: Write-Host "Hello, Café" |
| 84 | +
|
| 85 | + - name: Run with win_powershell |
| 86 | + ansible.windows.win_powershell: |
| 87 | + script: Write-Host "Hello, Café" |
| 88 | +
|
| 89 | +
|
| 90 | +Porting custom scripts |
| 91 | +====================== |
| 92 | + |
| 93 | +No notable changes |
| 94 | + |
| 95 | + |
| 96 | +Networking |
| 97 | +========== |
| 98 | + |
| 99 | +No notable changes |
0 commit comments