Reset user password

Reset password command

To reset a user's password, use the following command on the server where Databasus is running:

docker exec -it databasus ./main --new-password="YourNewSecurePassword123" --email="owner@example.com"

Parameters

The command accepts the following parameters:

  • --new-password: The new password. Make sure it's secure and contains a mix of letters, numbers and special characters.
  • --email: The email address of the account whose password you want to reset (e.g., owner@example.com). An instance created before the first account administered it still carries the placeholder address admin until its owner replaces it, so pass admin there.

List administrator accounts

If you do not remember which address administers the instance, list the administrator accounts on the server where Databasus is running:

docker exec -it databasus ./main --list-admins

The output names every administrator account with its email address, display name, creation date and active state, and marks the one the instance recognizes as its administrator. It prints no password, no password hash and no token. On an instance where nobody has created an account yet, it reports that the instance has no administrator.

Stop requiring a sign-in code

An instance can require a six-digit code emailed at sign-in on top of the password. If the mail server stops delivering those codes, nobody gets in with a password, and a password reset alone does not help. Switch the second factor off on the server where Databasus is running:

docker exec -it databasus ./main --disable-2fa

The command reports whether it changed anything, succeeds without complaint when the second factor is already off, and records the change in the audit log. The next password sign-in then needs no code, and an administrator can turn the setting back on once mail works again.