Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added information on keyword/vars separation #39561

Merged
merged 2 commits into from
May 25, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
16 changes: 16 additions & 0 deletions docs/docsite/rst/porting_guides/porting_guide_2.5.rst
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,22 @@ Included file:

The relevant change in those examples is, that in Ansible 2.5, the included file defines the tag ``distro_include`` again. The tag is not inherited automatically.

Fixed handling of keywords and inline variables
-----------------------------------------------

We made several fixes to how we handle keywords and 'inline variables', to avoid conflating the two. Unfortunately these changes mean you must specify whether `name` is a keyword or a variable when calling roles. If you have playbooks that look like this::

roles:
- { role: myrole, name: Justin, othervar: othervalue, become: True}

You will run into errors because Ansible reads name in this context as a keyword. Beginning in 2.5, if you want to use a variable name that is also a keyword, you must explicitly declare it as a variable for the role::

roles:
- { role: myrole, vars: {name: Justin, othervar: othervalue}, become: True}


For a full list of keywords see ::ref::`Playbook Keywords`.


Deprecated
==========
Expand Down