#212 Config script should explicitly fail when the bootstrap.env file is not present in the docker folder.

Merged
someonewithpc merged 1 commits from TiagoMagalhaes/v3-config-script-fix into diogo/v3 3 years ago

Description

When the bootstrap.env file is not present in docker/bootstrap, this means that the bootstrap_certificates script has not been run. Currently, this leads the configure script in bin to crash at line 10(pre-this pr. line 15 after this pr).

What this pr does is check if the bootstrap.env file exists, if it does not it outputs a message requesting the user to run the bootstrap_certificates and fails gracefully. If the file is present the script continues as normal.

This PR was tested under shellcheck and no additional warnings were introduced.

Testing

There are two scenarios that must be tested: when the bootstrap.env is present and when it is not.

Make sure you do not have the bootstrap.env file and run the configure from the root. What you should see is the message bootstrap.env missing! Please run the bootstrap_certificates script. show up and the script ends after that.

To test that it works normally when bootstrap.env is present just generate the file by running the bootstrap_certificates script and then you can run the configure configure script. In this case, the script should run normally as before querying you about your desired configuration information.

### Description When the `bootstrap.env` file is not present in `docker/bootstrap`, this means that the `bootstrap_certificates` script has not been run. Currently, this leads the `configure` script in `bin` to crash at line 10(pre-this pr. line 15 after this pr). What this pr does is check if the `bootstrap.env` file exists, if it does not it outputs a message requesting the user to run the `bootstrap_certificates` and fails gracefully. If the file is present the script continues as normal. This PR was tested under `shellcheck` and no additional warnings were introduced. ### Testing There are two scenarios that must be tested: when the `bootstrap.env` is present and when it is not. Make sure you do not have the `bootstrap.env` file and run the `configure` from the root. What you should see is the message `bootstrap.env missing! Please run the bootstrap_certificates script.` show up and the script ends after that. To test that it works normally when `bootstrap.env` is present just generate the file by running the `bootstrap_certificates` script and then you can run the `configure` configure script. In this case, the script should run normally as before querying you about your desired configuration information.
This pull request has been merged successfully!
Sign in to join this conversation.
No Milestone
No assignee
1 Participants
Loading...
Cancel
Save
There is no content yet.