-- The admin became an ordinary account with a flag, so the separate Basic Auth listener could go. -- Same integer-as-boolean convention as `banned` above it. alter table users add column is_admin integer not null default 0; -- An existing database already has its admin sitting in row one: the person who was handed the -- first invite from the old panel. A fresh database has no rows, so this is a no-op there and -- seedAdmin creates the account from the environment instead. update users set is_admin = 1 where id = (select min(id) from users);