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
fac7c6d3
Commit
fac7c6d3
authored
Jan 24, 2014
by
Adam Heath
Committed by
James Cammarata
Jan 27, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow su_user to be templated, same as sudo_user.
parent
b8d3c0f8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
lib/ansible/runner/__init__.py
+4
-2
No files found.
lib/ansible/runner/__init__.py
View file @
fac7c6d3
...
...
@@ -193,7 +193,8 @@ class Runner(object):
self
.
callbacks
.
runner
=
self
self
.
original_transport
=
self
.
transport
self
.
su
=
su
self
.
su_user
=
su_user
self
.
su_user_var
=
su_user
self
.
su_user
=
None
self
.
su_pass
=
su_pass
if
self
.
transport
==
'smart'
:
...
...
@@ -585,6 +586,8 @@ class Runner(object):
# late processing of parameterized sudo_user (with_items,..)
if
self
.
sudo_user_var
is
not
None
:
self
.
sudo_user
=
template
.
template
(
self
.
basedir
,
self
.
sudo_user_var
,
inject
)
if
self
.
su_user_var
is
not
None
:
self
.
su_user
=
template
.
template
(
self
.
basedir
,
self
.
su_user_var
,
inject
)
# allow module args to work as a dictionary
# though it is usually a string
...
...
@@ -629,7 +632,6 @@ class Runner(object):
actual_private_key_file
=
inject
.
get
(
'ansible_ssh_private_key_file'
,
self
.
private_key_file
)
self
.
sudo_pass
=
inject
.
get
(
'ansible_sudo_pass'
,
self
.
sudo_pass
)
self
.
su
=
inject
.
get
(
'ansible_su'
,
self
.
su_pass
)
self
.
su_user
=
inject
.
get
(
'ansible_su_user'
,
self
.
su_user
)
self
.
su_pass
=
inject
.
get
(
'ansible_su_pass'
,
self
.
su_pass
)
if
actual_private_key_file
is
not
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