IPA: psql command not working with sudo.
Issue
psql
command configured with double quotes inIPA
not working withsudo
. Failing with error.
$ sudo -i -u dev_user psql -c "SELECT NOW()"
[sudo] password for dev_user:
Sorry, user dev_user is not allowed to execute '/bin/bash -c psql -c SELECT\ NOW()' as tuser on server1.example.test.
psql
command configured with double quotes in/etc/sudoers
not working withsudo
Environment
- Red Hat Enterprise Linux 7
- Red Hat Enterprise Linux 8
- Red Hat Enterprise Linux 9
- IPA 4.x
- Sudo
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.