Advertisement
fkeles

add-sudoers.sh

May 10th, 2023
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.45 KB | Source Code | 0 0
  1. ## create a sudoers file
  2. [opc@inst-v3aqc-instance-pool4ml3doz8p2wlcqekw2 ~]$echo "ocarun ALL=(ALL) NOPASSWD:ALL" > ./101-oracle-cloud-agent-run-command
  3. ## verify it
  4. [opc@inst-v3aqc-instance-pool4ml3doz8p2wlcqekw2 ~]$ visudo -cf ./101-oracle-cloud-agent-run-command
  5. ./101-oracle-cloud-agent-run-command: parsed OK
  6. ## add the configuration
  7. [opc@inst-v3aqc-instance-pool4ml3doz8p2wlcqekw2 ~]$ sudo cp ./101-oracle-cloud-agent-run-command /etc/sudoers.d/
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement