summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonas Meurer <jonas@freesources.org>2018-04-05 20:05:38 +0200
committerMatt Davis <mrd@redhat.com>2018-04-18 10:08:58 -0700
commit5ea8fa4052f51b6a412356b3d84ad9b2f579051a (patch)
tree0a6cf3d847bf8e115f5ab973ed825018a9650765
parent5e8aeddc854b043899cfec0c0cf540db1c2335a0 (diff)
downloadansible-5ea8fa4052f51b6a412356b3d84ad9b2f579051a.tar.gz
Update porting_guide_2.5.rst (#37927)
The example regarding `include_*` is a bit unclear. First it seems like the v2.4 and v2.5 examples are the same. So I attempted to make the relevant change in the examples more obvious. label: docsite_pr (cherry picked from commit 55fd3d62fbcf8c29e2d84072a35327a916e3f332)
-rw-r--r--docs/docsite/rst/porting_guides/porting_guide_2.5.rst16
1 files changed, 14 insertions, 2 deletions
diff --git a/docs/docsite/rst/porting_guides/porting_guide_2.5.rst b/docs/docsite/rst/porting_guides/porting_guide_2.5.rst
index 2729c8b28f..bf773e4857 100644
--- a/docs/docsite/rst/porting_guides/porting_guide_2.5.rst
+++ b/docs/docsite/rst/porting_guides/porting_guide_2.5.rst
@@ -27,8 +27,7 @@ static ``import_*`` would be inherited by the tasks within.
This separation was only partially implemented in Ansible version 2.4. As of Ansible version 2.5, this work is complete and the separation now behaves as designed; attributes applied to an ``include_*`` task will not be inherited by the tasks within.
-To achieve an outcome similar to how Ansible worked prior to version 2.5, playbooks
-should use an explicit application of the attribute on the needed tasks, or use blocks to apply the attribute to many tasks. Another option is to use a static ``import_*`` when possible instead of a dynamic task.
+To achieve an outcome similar to how Ansible worked prior to version 2.5, playbooks should use an explicit application of the attribute on the needed tasks, or use blocks to apply the attribute to many tasks. Another option is to use a static ``import_*`` when possible instead of a dynamic task.
**OLD** In Ansible 2.4:
@@ -38,6 +37,17 @@ should use an explicit application of the attribute on the needed tasks, or use
tags:
- distro_include
+Included file:
+
+.. code-block:: yaml
+
+ - block:
+ - debug:
+ msg: "In included file"
+
+ - apt:
+ name: nginx
+ state: latest
**NEW** In Ansible 2.5:
@@ -63,6 +73,8 @@ Included file:
tags:
- distro_include
+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.
+
Deprecated
==========