I want to do sudo -i
within a bash script but also want to pass in the sudo username and password at the same time. Is that possible?
i.e. something like:
echo PASSWORD | sudo -k -S -i -u USERNAME
I want to do sudo -i
within a bash script but also want to pass in the sudo username and password at the same time. Is that possible?
i.e. something like:
echo PASSWORD | sudo -k -S -i -u USERNAME