Sudo'ing to a particular user now possible in the development branch (0.4)

Hi folks,

It is now possible on the devel branch to sudo to a particular user
where that user is NOT root. This is based on a patch from
weaselkeeper, who gets the award for the best handle on all of github,
plus some minor tweaks to make it work better with playbooks.

Usage from the command line is pretty simple:

ansible all -m ping -u yourUserName -s -U otherUserName

And from playbooks, there is a new playbook level variable available:

"sudo_user"

(As I have mentioned, I am working to make it available to specify
these kinds of things in the inventory file. This is coming.)

Sidenote -- no documentation on this feature just yet aside from this
email. At this point on the devel branch, after getting variable
handling between playbooks and the inventory file more unified, I'm
going to take a decent time off to update documentation -- we have
QUITE a few things in 0.4 to reflect. These will probably all start
with "(new in 0.4)" as it's not only useful development branch info,
it's also useful for encourage 0.3 users to upgrade once 0.4 is
released.

As with all things, help testing this is very welcome. From what
I've tried, it seems to be good. I have tried sudo'ing to batman,
for instance, and it would not let me... because I am not batman.

--Michael

So you say. But Bruce Wayne said the same thing many times. The question
is, have you and Batman ever been seen at the same place at the same time?

As with all things, help testing this is very welcome. From what
I’ve tried, it seems to be good. I have tried sudo’ing to batman,
for instance, and it would not let me… because I am not batman.

So you say. But Bruce Wayne said the same thing many times. The question
is, have you and Batman ever been seen at the same place at the same time?

This is a very good question.