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
edd5baad
Commit
edd5baad
authored
Apr 04, 2012
by
Jeroen Hoekx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refactor _transfer_argsfile to generic string transfer function.
parent
09e690fd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
lib/ansible/runner.py
+3
-3
No files found.
lib/ansible/runner.py
View file @
edd5baad
...
...
@@ -267,7 +267,7 @@ class Runner(object):
# *****************************************************
def
_transfer_
argsfile
(
self
,
conn
,
tmp
,
args_str
):
def
_transfer_
str
(
self
,
conn
,
tmp
,
name
,
args_str
):
''' transfer arguments as a single file to be fed to the module. '''
args_fd
,
args_file
=
tempfile
.
mkstemp
()
...
...
@@ -276,7 +276,7 @@ class Runner(object):
args_fo
.
flush
()
args_fo
.
close
()
args_remote
=
os
.
path
.
join
(
tmp
,
'arguments'
)
args_remote
=
os
.
path
.
join
(
tmp
,
name
)
conn
.
put_file
(
args_file
,
args_remote
)
os
.
unlink
(
args_file
)
...
...
@@ -355,7 +355,7 @@ class Runner(object):
module_name_tail
=
remote_module_path
.
split
(
"/"
)[
-
1
]
client_executed_str
=
"
%
s
%
s"
%
(
module_name_tail
,
args
.
strip
())
argsfile
=
self
.
_transfer_
argsfile
(
conn
,
tmp
,
args
)
argsfile
=
self
.
_transfer_
str
(
conn
,
tmp
,
'arguments'
,
args
)
if
async_jid
is
None
:
cmd
=
"
%
s
%
s"
%
(
remote_module_path
,
argsfile
)
else
:
...
...
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