-
Notifications
You must be signed in to change notification settings - Fork 509
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
common: Specify ansible_user var for local playbook run #5955
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 3 of 3 files at r1, all commit messages.
Reviewable status: complete! all files reviewed, all discussions resolved (waiting on @szczepax)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 3 of 3 files at r1, all commit messages.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @szczepax)
utils/ansible/README.md
line 116 at r1 (raw file):
For localhost execution with a local connection you should always pass `ansible_user=pmdkuser` as a variable due to [ansible_user Is Undefined on Localhost](https://radeksprta.eu/posts/ansible_user-is-undefined-on-localhost/).
Learned the hard way. But knowing that it is just how it works no mystery remains. If you would like to link something I prefer to link the official documentation. Even though it is not easy to read.
My suggestion is below. No links. Rather an explanation of what is the deal.
Suggestion:
It is possible to run playbooks directly on the target platform. In this case, you have to always pass `ansible_user=pmdkuser` as an additional variable since the playbooks are fine-tuned for remote execution and assume the `ansible_user` variable is defined. When running on a remote target the connection plugin does it for you.
utils/ansible/README.md
line 144 at r1 (raw file):
Example - GitHub self-hosted runner setup
No additional variables below this point. This variable is local-specific whereas the example is generic.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @janekmi)
utils/ansible/README.md
line 116 at r1 (raw file):
Previously, janekmi (Jan Michalski) wrote…
Learned the hard way. But knowing that it is just how it works no mystery remains. If you would like to link something I prefer to link the official documentation. Even though it is not easy to read.
My suggestion is below. No links. Rather an explanation of what is the deal.
Done.
utils/ansible/README.md
line 144 at r1 (raw file):
Previously, janekmi (Jan Michalski) wrote…
No additional variables below this point. This variable is local-specific whereas the example is generic.
ansible_user=pmdkuser is needed by "Create new namespace configuration" step
2e28363
to
57b8ed2
Compare
Continue on #6055 |
Ansible_user is undefined on Localhost with local connection and needs to be always passed with --extra-vars
https://radeksprta.eu/posts/ansible_user-is-undefined-on-localhost/
This change is