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
f939f3fd
Commit
f939f3fd
authored
Apr 27, 2012
by
Michael DeHaan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Playbook can now take a 'name' which it will show when starting the play
parent
67d11696
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
3 deletions
+5
-3
examples/playbooks/intro_example.yml
+2
-1
lib/ansible/playbook.py
+3
-2
No files found.
examples/playbooks/intro_example.yml
View file @
f939f3fd
...
...
@@ -7,7 +7,8 @@
# on all hosts, run as the user root...
-
hosts
:
all
-
name
:
example play
hosts
:
all
user
:
root
# could have also have done:
...
...
lib/ansible/playbook.py
View file @
f939f3fd
...
...
@@ -553,7 +553,8 @@ class PlayBook(object):
''' run a list of tasks for a given pattern, in order '''
# get configuration information about the pattern
pattern
=
pg
.
get
(
'hosts'
,
None
)
pattern
=
pg
.
get
(
'hosts'
,
None
)
name
=
pg
.
get
(
'name'
,
pattern
)
if
isinstance
(
pattern
,
list
):
pattern
=
';'
.
join
(
pattern
)
if
self
.
override_hosts
:
...
...
@@ -570,7 +571,7 @@ class PlayBook(object):
sudo
=
pg
.
get
(
'sudo'
,
self
.
sudo
)
transport
=
pg
.
get
(
'connection'
,
self
.
transport
)
self
.
callbacks
.
on_play_start
(
pattern
)
self
.
callbacks
.
on_play_start
(
name
)
# push any variables down to the system # and get facts/ohai/other data back up
self
.
_do_setup_step
(
pattern
,
vars
,
user
,
port
,
sudo
,
transport
,
None
)
...
...
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