旅館 Ryokan

Account recovery

Ryokan stores the admin account in the same SQLite database as the rest of its config. There are two ways to recover access if you've forgotten your password. Both only wipe the users and sessions tables; your Jellyfin / download-client credentials and other settings survive the reset.

Option 1: restart with the reset flag

On the machine running Ryokan:

  1. Create an empty sentinel file named .reset-auth next to ryokan.db. That is the folder RYOKAN_DATA_DIR names if you set it, /data in Docker otherwise, and data in the folder Ryokan runs from outside Docker.
  2. Restart Ryokan with the environment variable RYOKAN_RESET_AUTH=1 set, or with the --reset-auth CLI flag.
  3. Open Ryokan in your browser. You'll be redirected to the first-run setup page. Create a new admin account.
  4. Unset RYOKAN_RESET_AUTH. Ryokan removes the sentinel file itself once the reset has run, so a forgotten env var can't wipe the account again.

The sentinel file is required so that a stuck-on RYOKAN_RESET_AUTH=1 in a docker-compose.yml can't accidentally wipe auth on every boot. Recovery is always a deliberate two-step action.

Option 2: sqlite3 recipe

If you can't easily restart Ryokan with a new environment variable (e.g. you're on a managed deployment), shut Ryokan down and run this once against the database:

sqlite3 data/ryokan.db "DELETE FROM users; DELETE FROM sessions;"

Then start Ryokan back up and create a new admin account through the first-run setup.

Back to Sign In