I encountered the following error today while installing a few packages on a ubuntu server using a sudo user.
“sudo: sorry, you are not allowed to set the following environment variables: DEBIAN_FRONTEND”
The command I ran was: “sudo DEBIAN_FRONTEND=noninteractive apt-get install -qy git-core”
I did search on google and did’nt find any direct answer for this error. Then I somehow figured out that if we change env_reset line in sudoers file then it allows sudo user to set environment.
I don’t have any idea, what could be consequences of this change. So I reverted it after my job is done.