Add new unified database, migrate actor data
johnholdun opened this issue · comments
John Holdun commented
The app currently stores data and configuration across two SQLite databases and a static JSON file. This issue describes the first part of a multi-step process to consolidate these stores into one new SQLite database, enabling more flexibility in administrative settings and general long-term stability. Extracted from #6, as written by @ckolderup:
- Create a new application.db database file with a unified
setup
process that establishes the new schema + migration process with a barebones schema - Create a process by which the setup process detects existing account.json + activitypub.db actor singleton tables and imports them into an application.db
settings
table with schema defined in the migration .sql file (or files). - Make the application code read this info from application.db instead of account.json/activitypub.db. Add the admin settings to manage the relevant settings data in application.db to make account.json obsolete. Set things up so that on startup, if all the required
settings
table key/value pairs are present, the owner is notified that they can remove account.json from their filesystem.