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

winrm: source user from options than remote_user #40467

Merged
merged 4 commits into from
May 21, 2018

Conversation

jborean93
Copy link
Contributor

SUMMARY

When sourcing the username we currently get it from the play context. Because ansible_ssh_user is a global fallback it overrides ansible_user even if that is set at a higher var level. This also fixes the issue where ansible_winrm_user does not work at all.

Fixes #39844

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

winrm

ANSIBLE VERSION
devel

@ansibot
Copy link
Contributor

ansibot commented May 21, 2018

@ansibot ansibot added affects_2.6 This issue/PR affects Ansible v2.6 bug This issue/PR relates to a bug. needs_triage Needs a first human triage before being processed. new_plugin This PR includes a new plugin. support:core This issue/PR relates to code supported by the Ansible Engineering Team. test This PR relates to tests. windows Windows community needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. labels May 21, 2018
@ansibot ansibot removed the needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. label May 21, 2018
@jborean93 jborean93 merged commit 1ac180c into ansible:devel May 21, 2018
@jborean93 jborean93 deleted the winrm-user-source branch May 21, 2018 23:36
jborean93 added a commit to jborean93/ansible that referenced this pull request May 21, 2018
* winrm: source user from options than remote_user

* fixed up mock for kerberos import

* Added changelog fragment

* get hostname from option as well

(cherry picked from commit 1ac180c)
@jborean93
Copy link
Contributor Author

Backport PR to stable-2.5 #40516

jborean93 added a commit that referenced this pull request May 22, 2018
* winrm: source user from options than remote_user (#40467)

* winrm: source user from options than remote_user

* fixed up mock for kerberos import

* Added changelog fragment

* get hostname from option as well

(cherry picked from commit 1ac180c)

* Also removed uneeded method that wasn't backported
achinthagunasekara pushed a commit to achinthagunasekara/ansible that referenced this pull request May 23, 2018
* winrm: source user from options than remote_user

* fixed up mock for kerberos import

* Added changelog fragment

* get hostname from option as well
@sivel sivel removed the needs_triage Needs a first human triage before being processed. label May 23, 2018
jacum pushed a commit to jacum/ansible that referenced this pull request Jun 26, 2018
* winrm: source user from options than remote_user

* fixed up mock for kerberos import

* Added changelog fragment

* get hostname from option as well
ilicmilan pushed a commit to ilicmilan/ansible that referenced this pull request Nov 7, 2018
* winrm: source user from options than remote_user

* fixed up mock for kerberos import

* Added changelog fragment

* get hostname from option as well
@ansible ansible locked and limited conversation to collaborators May 22, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.6 This issue/PR affects Ansible v2.6 bug This issue/PR relates to a bug. new_plugin This PR includes a new plugin. support:core This issue/PR relates to code supported by the Ansible Engineering Team. test This PR relates to tests. windows Windows community
Projects
None yet
Development

Successfully merging this pull request may close these issues.

winrm inventory ansible_user masked by prior ansible_ssh_user setting
3 participants