Run Jenkins with Super User Privilege on the server

Posted By : Rijul Jain | 03-Jun-2015


Last week I came across a requirement where I had to deploy an application on the root (port:80) for which I was getting an "Authentication Failure issue" with the following error: "sudo: no tty present and no askpass program specified" for which I did the following:

  1. Browse to the "sudoers" file, present in the /etc directory on your system.
  2. Open the  sudoers file and add the following entry to the same:
    %jenkins ALL=NOPASSWD: ALL
  3. Save and exit from the file,and you're done!

Caution: This allows JENKINS to avoid the password prompt for all commands, which could

be unsafe. So please use this with caution.

About Author

Author Image
Rijul Jain

Rijul has more than 10 years of experience in software development, filling positions of both technical and managerial leadership. He loves to travel and indulge in gaming in his free time.

Request for Proposal

Name is required

Comment is required

Sending message..