Zammad: Locked myself out, can't login again..

Created on 4 Jul 2017  路  1Comment  路  Source: zammad/zammad

I don't know why or how, but my user stopped working and wouldn't reset password (said user didn't exist).

So, I sent an e-mail to the default mail (in order to get my email on the system) and it worked, I was able to reset my password.

Except I'm now a regular user and there are no more admin users.

How can I reset everything? Or forcefully add an admin user?

Most helpful comment

Hi @madd86 ,

did you try it with the ruby on rails zammad console?
https://docs.zammad.org/en/latest/admin-console.html?highlight=admin
An important point is, you need to be in your zammad directory
At the bottom, there is a description how you can give an user the admin rol
https://docs.zammad.org/en/latest/admin-console.html?highlight=admin#set-admin-rights-for-user

Set admin rights for user

rails> u = User.find_by(email: '[email protected]')
rails> u.roles = Role.where(name: ['Agent', 'Admin'])
rails> u.save!

>All comments

Hi @madd86 ,

did you try it with the ruby on rails zammad console?
https://docs.zammad.org/en/latest/admin-console.html?highlight=admin
An important point is, you need to be in your zammad directory
At the bottom, there is a description how you can give an user the admin rol
https://docs.zammad.org/en/latest/admin-console.html?highlight=admin#set-admin-rights-for-user

Set admin rights for user

rails> u = User.find_by(email: '[email protected]')
rails> u.roles = Role.where(name: ['Agent', 'Admin'])
rails> u.save!
Was this page helpful?
0 / 5 - 0 ratings