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
b779fa4f
Commit
b779fa4f
authored
Apr 10, 2013
by
Trevor Wennblom
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
make json valid
parent
290780d1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
17 deletions
+17
-17
docsite/rst/api.rst
+16
-16
docsite/rst/moduledev.rst
+1
-1
No files found.
docsite/rst/api.rst
View file @
b779fa4f
...
...
@@ -40,7 +40,7 @@ expressed in the 'ansible-modules' documentation.::
{
"dark" : {
"web1.example.com" : "failure message"
}
}
,
"contacted" : {
"web2.example.com" : 1
}
...
...
@@ -110,22 +110,22 @@ Each group's value should be either a hash/dictionary containing a list of each
simply a list of host/IP addresses, like so::
{
'databases'
: {
'hosts' : [ 'host1.example.com', 'host2.example.com'
],
'vars'
: {
'a'
: true
"databases"
: {
"hosts" : [ "host1.example.com", "host2.example.com"
],
"vars"
: {
"a"
: true
}
},
'webservers' : [ 'host2.example.com', 'host3.example.com'
],
'atlanta'
: {
'hosts' : [ 'host1.example.com', 'host4.example.com', 'host5.example.com'
],
'vars'
: {
'b'
: false
"webservers" : [ "host2.example.com", "host3.example.com"
],
"atlanta"
: {
"hosts" : [ "host1.example.com", "host4.example.com", "host5.example.com"
],
"vars"
: {
"b"
: false
},
'children': [ 'marietta', '5points'
],
"children": [ "marietta", "5points"
],
},
'marietta' : [ 'host6.example.com'
],
'5points' : [ 'host7.example.com'
]
"marietta" : [ "host6.example.com"
],
"5points" : [ "host7.example.com"
]
}
.. versionadded: 1.0
...
...
@@ -137,9 +137,9 @@ hash/dictionary, or a hash/dictionary of variables to make available to template
if the script does not wish to do this, returning an empty hash/dictionary is the way to go::
{
'favcolor' : 'red'
,
'ntpserver' : 'wolf.example.com'
,
'monitoring' : 'pack.example.com'
"favcolor" : "red"
,
"ntpserver" : "wolf.example.com"
,
"monitoring" : "pack.example.com"
}
Example: The Cobbler External Inventory Script
...
...
docsite/rst/moduledev.rst
View file @
b779fa4f
...
...
@@ -180,7 +180,7 @@ Let's test that module::
This should return something like::
{"changed":
T
rue, "time": "2012-03-14 12:23:00.000307"}
{"changed":
t
rue, "time": "2012-03-14 12:23:00.000307"}
Module Provided 'Facts'
```````````````````````
...
...
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