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
86dc83b7
Commit
86dc83b7
authored
Mar 19, 2015
by
Toshio Kuratomi
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #10163 from maxamillion/docs_yaml_dict_playbook
Add intro to playbook docs using YAML dictionaries
parents
ac1c4930
1e787bd9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
37 additions
and
0 deletions
+37
-0
docsite/rst/playbooks_intro.rst
+37
-0
No files found.
docsite/rst/playbooks_intro.rst
View file @
86dc83b7
...
...
@@ -73,6 +73,43 @@ For starters, here's a playbook that contains just one play::
-
name
:
restart
apache
service
:
name
=
httpd
state
=
restarted
We
can
also
break
task
items
out
over
multiple
lines
using
the
YAML
dictionary
types
to
supply
module
arguments
.
This
can
be
helpful
when
working
with
tasks
that
have
really
long
parameters
or
modules
that
take
many
parameters
to
keep
them
well
structured
.
Below
is
another
version
of
the
above
example
but
using
YAML
dictionaries
to
supply
the
modules
with
their
key
=
value
arguments
.::
---
-
hosts
:
webservers
vars
:
http_port
:
80
max_clients
:
200
remote_user
:
root
tasks
:
-
name
:
ensure
apache
is
at
the
latest
version
yum
:
pkg
:
httpd
state
:
latest
-
name
:
write
the
apache
config
file
template
:
src
:
/
srv
/
httpd
.
j2
dest
:
/
etc
/
httpd
.
conf
notify
:
-
restart
apache
-
name
:
ensure
apache
is
running
service
:
name
:
httpd
state
:
started
handlers
:
-
name
:
restart
apache
service
:
name
:
httpd
state
:
restarted
..
note
::
The
above
example
using
YAML
dictionaries
for
module
arguments
can
also
be
accomplished
using
the
YAML
multiline
string
syntax
with
the
`>`
character
but
this
can
lead
to
string
quoting
errors
.
Below
,
we
'll break down what the various features of the playbook language are.
.. _playbook_basics:
...
...
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