Upgrade and back up ParseHawk
ParseHawk keeps its local database, uploaded files, provider-secret key, runtime state, logs, and traces under the configured data directory. Back up that directory as one unit.
Back up a local installation
Section titled “Back up a local installation”Stop services before copying SQLite and file storage:
parsehawk stopcp -a data "data.backup.$(date +%Y%m%d-%H%M%S)"If data.dir points elsewhere, use the path shown by parsehawk config list.
Protect the backup like the source documents it contains.
Upgrade a source checkout
Section titled “Upgrade a source checkout”git pull --ff-onlyuv tool install --editable . --forceparsehawk startparsehawk start applies pending ordered migrations before serving traffic. To
inspect them first:
parsehawk migrate statusControl migration timing
Section titled “Control migration timing”Operators who need a maintenance window can opt out of startup migrations:
parsehawk start -x migrateparsehawk migrate statusparsehawk migrateparsehawk restartThe equivalent environment override is PARSEHAWK_SKIP_MIGRATIONS=1.
Restore
Section titled “Restore”parsehawk stopmv data data.failedcp -a data.backup.YYYYMMDD-HHMMSS dataparsehawk startparsehawk doctorProvider API keys depend on the encryption key stored with the data directory,
or on the same PARSEHAWK_SECRET_KEY override. Restoring only the database can
make stored credentials unreadable.
Do not remove a live data directory. Existing processes can keep open SQLite handles and continue serving unexpected state.