Jenkins Security - Unable to login

前端 未结 8 2453
北海茫月
北海茫月 2020-12-14 10:05

I enabled security on Jenkins and added myself as the only user. After clicking on \"Save\" it brought me back to the log-on screen without asking me to create a password. N

8条回答
  •  情话喂你
    2020-12-14 10:15

    I solved it. Here's what I did.

    1. I disabled security in JENKINS_HOME/config.xml

    2. Restarted Tomcat

    3. I re-enabled security

    4. Selected Jenkin's own database and also checked Allow users to Sign-up (Also make sure that in Authorization, "Anyone can do anything" is ticked.)

    5. "Save". After clicking Save, it will bring you to the initial page, then on the top-right corner there is a "Sign up" link.

    6. Click on "Sign up", enter your username and password then log-in. Right now you are the only registered user. But it actually did something else. Prior to the creation of your first account, there is no "Manage users" in the "Manage Jenkins" menu. I saw this guide on adding users to Jenkins and it says that there should be a "Manage users" link under the "Manage Jenkins" menu but there is none. But after you have created your first account (using Sign up), you can now find it there.

    7. Add users on the "Manage users" and then go back to "Manage security" then disable "Allow users to sign up". Also, you can now use Matrix based authentication without having to worry about getting locked out of Jenkins.

    I hope someone can find this useful.

    Cheers.

提交回复
热议问题