Updating the database on startup

Admins who wish to preconfigure the FastX database, or forcibly add information to the database can do so on startup.  This is useful if you want to deploy configurations across multiple isolated servers (not in a cluster), or need to do something like reset the admin password

  1. Create a file: /usr/lib/fastx/var/config/override.json
    • The file is an array of JSON objects with the information that will be added to the database
    • Each JSON object must contain an _id parameter which is the CouchDB required _id of the object
  2. Restart the web server

On startup, the web server will read this file and overwrite any data that is in the object with the _id.
After the file is read, it will rename itself so that it is only written once.