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
fd4ae165
Commit
fd4ae165
authored
Jan 06, 2014
by
jctanner
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #5153 from willthames/ec2_inventory_multiuser
Allow multiple users to use ec2 inventory scripts
parents
5c64d703
3a0d2860
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
4 deletions
+7
-4
plugins/inventory/ec2.ini
+1
-1
plugins/inventory/ec2.py
+6
-3
No files found.
plugins/inventory/ec2.ini
View file @
fd4ae165
...
...
@@ -47,7 +47,7 @@ route53 = False
# will be written to this directory:
# - ansible-ec2.cache
# - ansible-ec2.index
cache_path
=
/tmp
cache_path
=
~/.ansible
/tmp
# The number of seconds a cache file is considered valid. After this many
# seconds, a new API call will be made, and the cache file will be updated.
...
...
plugins/inventory/ec2.py
View file @
fd4ae165
...
...
@@ -223,9 +223,12 @@ class Ec2Inventory(object):
config
.
get
(
'ec2'
,
'route53_excluded_zones'
,
''
)
.
split
(
','
))
# Cache related
cache_path
=
config
.
get
(
'ec2'
,
'cache_path'
)
self
.
cache_path_cache
=
cache_path
+
"/ansible-ec2.cache"
self
.
cache_path_index
=
cache_path
+
"/ansible-ec2.index"
cache_dir
=
os
.
path
.
expanduser
(
config
.
get
(
'ec2'
,
'cache_path'
))
if
not
os
.
path
.
exists
(
cache_dir
):
os
.
makedirs
(
cache_dir
)
self
.
cache_path_cache
=
cache_dir
+
"/ansible-ec2.cache"
self
.
cache_path_index
=
cache_dir
+
"/ansible-ec2.index"
self
.
cache_max_age
=
config
.
getint
(
'ec2'
,
'cache_max_age'
)
...
...
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