Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Getting "Error: you must authenticate to access this jenkins" when trying to run "Java -jar jenkins-cls.jar -s http://localhost:8080 /help"

Tags:

jenkins

Getting below error

Error: you must authenticate to access this jenkins" when trying to run "Java -jar jenkins-cls.jar -s http://localhost:8080 /help

Steps performed as below,
1. Copied jenkins-cls.jar to the local drive.
2. Opened command prompt and navigate to path where jenkins-cls.jar is saved.
3. Type "Java -jar jenkins-cls.jar -s http://localhost:8080 /help" and press enter.

It should ask for pass-code but instead, it displayed message "Error: you must authenticate to access this jenkins".

Any help to resolve this query is highly appreciated.

like image 808
Yatish Pokale Avatar asked Sep 14 '17 13:09

Yatish Pokale


1 Answers

The file name is now changed from jenkins-cls.jar to jenkins-cli.jar.

Make sure the user is registered in jenkins front-end and Enable Security is checked for the user.

java -jar jenkins-cli.jar -s http://localhost:8080 -auth username:password
like image 122
Mian Asbat Ahmad Avatar answered Nov 12 '22 21:11

Mian Asbat Ahmad