Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cwd needs to be passed from runas() to runas_system() #50415

merged 1 commit into from Nov 8, 2018


None yet
5 participants
Copy link

commented Nov 7, 2018

Fixes parts of #47787

What does this PR do?

47787 ends with a comment that something has fixed in develop which could be backported.
Since this might be a major effort, my suggestion is to first merge my little fix which is much easier to do.
While I'm no expert neither in salt nor in windows, my change seems straightforward enough to be harmless ;)

What issues does this PR fix or reference?

with my fix, the cwd parameter gets gets passed into the runas_system() method

Previous Behavior

salt myminion "dir" runas=myuser password=mysecret cwd=C:/Windows/Temp
would be executed in C:/salt

New Behavior

salt myminion "dir" runas=myuser password=mysecret cwd=C:/Windows/Temp
would be executed in C:/Windows/Temp

Tests written?


Commits signed with GPG?


Please review Salt's Contributing Guide for best practices.

See GitHub's page on GPG signing for more information about signing commits with GPG.

Friedmund Lassmann Friedmund Lassmann

@salt-jenkins salt-jenkins requested a review from saltstack/team-windows Nov 7, 2018


This comment has been minimized.

Copy link

commented Nov 7, 2018

@dwoz Thoughts?

@dwoz dwoz requested review from dwoz and twangboy Nov 8, 2018


dwoz approved these changes Nov 8, 2018

@rallytime rallytime merged commit 93095cb into saltstack:2017.7 Nov 8, 2018

9 checks passed

continuous-integration/jenkins/pr-merge This commit looks good
jenkins/pr/docs The docs job has passed
jenkins/pr/lint The lint job has passed
jenkins/pr/py2-centos-7 The py2-centos-7 job has passed
jenkins/pr/py2-ubuntu-1604 The py2-ubuntu-1604 job has passed
jenkins/pr/py2-windows-2016 The py2-windows-2016 job has passed
jenkins/pr/py3-centos-7 The py3-centos-7 job has passed
jenkins/pr/py3-ubuntu-1604 The py3-ubuntu-1604 job has passed
jenkins/pr/py3-windows-2016 The py3-windows-2016 job has passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.