builder-web: Added --cachedir CLI param for staging new vizs #102
Merged
rand
merged 5 commits from 20220329_passing_separate_cache-dir
into main
10 months ago
Loading…
Reference in new issue
There is no content yet.
Delete Branch '20220329_passing_separate_cache-dir'
Deleting a branch is permanent. It CANNOT be undone. Continue?
Intention is to pass a custom cache-dir when staging new vizs to test them - but still run up against the production data-dir
| `Linux -> "/var/lib/builder-web"
let default_cachedir =
default_datadir ^ "/_cache"
what if someone passes a datadir explicitly, but not a cache dir? then the cache dir will be
default_datadir ^ /_cache
, while I'd expectdatadir ^ /_cache
.Ah yes, good catch
I don't quite understand the issue you're trying to solve... Is this related to what we talked about versioning and migration?
The scripts in
packaging
also need to be changed to optionally use this parameterThe issue is that we on shell.robur.io run a 'production' builder-web and a 'staging' builder-web - both running up against the same builds directory. This makes it possible to test a new version of builder-web with all the data.
The problem arises if one wants to test new visualizations @ staging and still use the same builds directory. Currently, if one changes the cache of vizs @ staging, one changes it for production too.
let cachedir = match cachedir with
| Some c -> Fpath.v c
| None -> Fpath.(datadir / "_cache")
in
Option.value ~default:Fpath.(datadir / "_cache") cachedir
$ influx
$ port $ host
$ datadir $ cachedir $ configdir
) in
I find this indentation weird: I'd either fill until 80 chars or put a newline after/before each
$
.Great, looks good to me apart from minor nits. :)
I added a commit addressing the minor nits. This is fine to merge!
2e601ac181
into main 10 months ago2e601ac181
.