On Fri, Oct 26, 2012 at 9:02 AM, Nolan Darilek <
no...@thewordnerd.info> wrote:
> On 10/25/2012 02:50 PM, Jan-Piet Mens wrote:
>>
>> I think most of us use sudo-less setups, so we don't really want the sudo
>> password...
>
>
>
> As in, just connecting to the remote system as root? Or via some other
> mechanism? I thought it was always best practice to disable direct login to
> the root account and go through sudo, but perhaps disabling passwordless SSH
> and using keys makes things safe enough to enable the root account?
No, passwordless sudo.
http://linux-tips.org/article/18/passwordless-sudo-setup
But yes, there's really no difference between the two.
I am not sure what you mean by "disabling passwordless SSH and using
keys". You've either got
passwords or keys :)
>
> If the playbook specifies "sudo: true", would it be safe to assume -K? Or is
> there a scenario where someone may specifically request sudo but not want to
> prompt for a password? How many people use sudo without a password vs. using
> it with one, and if the ratio is low, maybe prompting for the password in
> these circumstances might be a better default?
No, "-K" means prompt me for a sudo password.
Again, sudo does not require a password.
Choosing interactivity by default is something Ansible will never do,
nor is the ratio low. It defeats the purposes of an automation
solution.