Closed MattiSG closed 6 years ago
Should close #167.
Alright, thanks everybody for the thoughtful reviews. We're finally ready to merge! I just rebased, checked the diff, and will merge as soon as CI passes.
@openfisca/france-admin beware! As I did not get any reply in the last 18 days regarding deployment updates, I decided to take the safest direction and deactivated autodeploy (see 5da4e75). I will let you open another PR if you want to use CI for CD again.
@openfisca/aotearoa you should be ready to use with Heroku! Let me know if you need more help than what was explained earlier in https://github.com/openfisca/legislation-explorer/pull/165#issue-203043794 🙂
We're stuck because of https://github.com/openfisca/legislation-explorer/issues/169.
Fastest way out of this for @openfisca/aotearoa who would like to switch to Heroku is to merge this branch into the master of your fork.
Best solution is to open a separate PR to switch integration tests to the country template.
Necessary feature is to support the new slash syntax.
Main objective and features
This changeset shifts the configuration mechanism from file-based to environment variables.
This allows to create instances for new tax and benefit systems (countries) without committing a full config file to the shared repository, leaving it to each instance to define their configuration at runtime.
This also allows to run the Legislation Explorer on application-level cloud providers (PaaS) such as Heroku, which do not allow modification of the filesystem between checkout and execution.
In order to facilitate usage, support is also provided for a
.env
file that can list all environment variables, for these cases where the operator has control over the filesystem.This changeset also:
Clients impact
All automatic deployments will fail when this PR is merged. Since the configuration mechanism now relies on variables being injected, you will need to update your setup to define these variables.
For convenience, here are the previously defined configuration files as
.env
files, as well as suggested migration paths:France
Define a
.env
file at the root of the current clone with the following data:Tunisia
Define a
.env
file at the root of the current clone with the following data:Aotearoa
master
.