Skip to content
Discussion options

You must be logged in to vote

There is no need to guess the permission payload if the goal is only to put an existing user back into the built-in Administrators group. In the v2 schema the relation table is userGroups, users are in users, and groups are in groups. The setup code creates the system group named Administrators with manage:system, and assigns the initial admin by relating the user to that group.

Safest recovery route:

  1. Stop the Wiki.js container, or at least make sure nobody is changing users/groups.
  2. Take a database backup.
  3. Look up the target user and the admin group:
SELECT id, email, name FROM users WHERE email = 'person@example.com';
SELECT id, name, permissions FROM groups WHERE name = 'Administrators';

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by JulianOliver
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants