Open walkloud opened 4 years ago
Yes, the PR #42 implements this. Notes on how to use it are in the how-to-use-local-dbs.md
:
This file specifies how to create a local back up of formfac.correlator
data.
feature-dual-db
branchdb-config.yaml
is set up such that you connect to the ithems postgres dbdb-config-local.yaml
with the content (this will spawn the sqlite db for copying data back and forth)ENGINE: django.db.backends.sqlite3
NAME: /path/to/local/file/db-name.sqlite
python makemigrations
)lattedb migrate --database=local
python clone_corrs.py -n
Done. You can now copy this file to any new machine and work with it.
rsync
the local db /path/to/local/file/db-name.sqlite
to your remote machine.db-config.yaml
to the local config (note this is a different setting than on the machine used for cloning)ENGINE: django.db.backends.sqlite3
NAME: /remote/path/to/local/file/db-name.sqlite
rsync
the remote db /remote/path/to/local/file/db-name.sqlite
back to your local machine (same place as before).python clone_corrs.py -u
This runs some checks and asks you if things make sense before continuing, still someone else may want to test this :)
does this work already? I can't recall - but the ability to point the db to a local copy to update - I guess even if it works, I don't know how to recombine the DB to the master...