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
8a61303c
Commit
8a61303c
authored
Oct 30, 2014
by
Tom Berger
Committed by
Abhijit Menon-Sen
Aug 11, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move the cache file to ~/.ansible/tmp.
A future branch might make it configurable.
parent
07a4076d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
contrib/inventory/rax.py
+4
-2
No files found.
contrib/inventory/rax.py
View file @
8a61303c
...
...
@@ -167,7 +167,6 @@ except ImportError:
print
(
'pyrax is required for this module'
)
sys
.
exit
(
1
)
from
tempfile
import
gettempdir
from
time
import
time
...
...
@@ -345,7 +344,10 @@ def _list_into_cache(regions):
def
get_cache_file_path
(
regions
):
regions_str
=
'.'
.
join
([
reg
.
strip
()
.
lower
()
for
reg
in
regions
])
return
os
.
path
.
join
(
gettempdir
(),
ansible_tmp_path
=
os
.
path
.
join
(
os
.
path
.
expanduser
(
"~"
),
'.ansible'
,
'tmp'
)
if
not
os
.
path
.
exists
(
ansible_tmp_path
):
os
.
makedirs
(
ansible_tmp_path
)
return
os
.
path
.
join
(
ansible_tmp_path
,
'ansible-rax-
%
s-
%
s.cache'
%
(
pyrax
.
identity
.
username
,
regions_str
))
...
...
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