00.as_root-remove_sudo_password.sh 204 B

1234567891011
  1. #!/bin/bash
  2. # fail if any commands fails
  3. set -e
  4. # debug log
  5. #set -x
  6. apt-get -y --fix-missing install sudo
  7. read -rp "Enter user name: " username
  8. echo "${username} ALL=(ALL) NOPASSWD: ALL" >>/etc/sudoers