Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
ansible
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
ansible
Commits
7062cb3b
Commit
7062cb3b
authored
Aug 06, 2015
by
Brian Coca
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
removed soon to be deprecated role like include syntax
parent
e16b24c0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
13 deletions
+8
-13
docsite/rst/playbooks_roles.rst
+8
-13
No files found.
docsite/rst/playbooks_roles.rst
View file @
7062cb3b
...
@@ -65,19 +65,6 @@ contain all of my wordpress tasks in a single wordpress.yml file, and use it lik
...
@@ -65,19 +65,6 @@ contain all of my wordpress tasks in a single wordpress.yml file, and use it lik
- include: wordpress.yml wp_user=alice
- include: wordpress.yml wp_user=alice
- include: wordpress.yml wp_user=bob
- include: wordpress.yml wp_user=bob
If you are running Ansible 1.4 and later, include syntax is streamlined to match roles, and also allows passing list and dictionary parameters::
tasks:
- { include: wordpress.yml, wp_user: timmy, ssh_keys: [ 'keys/one.txt', 'keys/two.txt' ] }
Using either syntax, variables passed in can then be used in the included files. We'll cover them in :doc:`playbooks_variables`.
You can reference them like this::
{{ wp_user }}
(In addition to the explicitly passed-in parameters, all variables from
the vars section are also available for use here as well.)
Starting in 1.0, variables can also be passed to include files using an alternative syntax,
Starting in 1.0, variables can also be passed to include files using an alternative syntax,
which also supports structured variables::
which also supports structured variables::
...
@@ -90,6 +77,14 @@ which also supports structured variables::
...
@@ -90,6 +77,14 @@ which also supports structured variables::
- keys/one.txt
- keys/one.txt
- keys/two.txt
- keys/two.txt
Using either syntax, variables passed in can then be used in the included files. We'll cover them in :doc:`playbooks_variables`.
You can reference them like this::
{{ wp_user }}
(In addition to the explicitly passed-in parameters, all variables from
the vars section are also available for use here as well.)
Playbooks can include other playbooks too, but that's mentioned in a later section.
Playbooks can include other playbooks too, but that's mentioned in a later section.
.. note::
.. note::
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment