Tag Info

New answers tagged

0

This is a quite old thread, nonetheless: We use two different authentication systems in-house, management of machines is done from local workstations in my team. I wrote a vars_plugin for Ansible (a rather complete implementation may be found at https://gist.github.com/mfriedenhagen/e488235d732b7becda81) which differentiates several authentication systems: ...


0

You might try sudo su drupaluser and check out man su.


0

Assuming we're talking about this error: $ sudo su - bob $ screen Cannot open your terminal '/dev/pts/5' - please check. Here's a one-liner (could be used as "alias gobob", for example): sudo su - bob -c "script -c bash /dev/null"' Explanation: This will start a shell (like login shell) as user bob. User bob starts script, which is told to invoke a ...


2

If the script is running in root's crontab, you should remove 'sudo' from the command. I've seen this before, where trying to 'sudo' when you're already root makes the command fail. If you want to switch user, then the command when run as root, is 'su -l jira', not sudo -u jira.


2

Try this; ansible example -a "id" --sudo -K This runs the command using ansible's built in sudo function which will utilize the -K (ask-sudo-pass) flag. If you try to run sudo within the command, it will not use the -K (--ask-sudo-pass) password.


0

Give this a try: $ sudo -E indexer index



Top 50 recent answers are included