mentorship-backend icon indicating copy to clipboard operation
mentorship-backend copied to clipboard

Create an Installation script to automatically install and setup the project

Open xprilion opened this issue 5 years ago • 8 comments

Is your feature request related to a problem? Please describe. Currently the installation and setup of Mentorship Backend is done manually. It would be great to have a single script which could download the code and setup the various configurations required automatically.

Describe the solution you'd like Create a shell script named install.sh (for Linux/Mac) or install.bat (for Windows) which would do the following when run - - Clone the repository to the present working directory of the running script (if not already inside one, which will mostly be the case ) - Perform all the required setup for the repository to run. Take any variable inputs as mandatory command line arguments, without which the script will produce an error, and prompt the user to enter the values. - Perform unit testing on the installation and display its results

Describe alternatives you've considered To modify the deploy.sh file to work on local systems

xprilion avatar Nov 20 '19 15:11 xprilion

@isabelcosta There is a GCI task associated with this, maybe we can tag it as GCI

sara-02 avatar Nov 29 '19 10:11 sara-02

Sounds good @sara-02 and @xprilion ! I will label this as "Program: GCI".

isabelcosta avatar Nov 30 '19 22:11 isabelcosta

Reference PR: https://github.com/systers/mentorship-backend/pull/203

sara-02 avatar Dec 02 '19 06:12 sara-02

Working on it!

daksha-aeer avatar Dec 12 '19 03:12 daksha-aeer

Just copy pasting my comments from the PR https://github.com/systers/mentorship-backend/pull/267/ for future work on this script, which requires some discussion For future I am just adding a comment, how can we further improve the installation process if some parts of the script fail. Like if even one of the env fails, the script exits. But I cannot run the script again without first deleting the mentorship-backend folder. Or how can we detach the python run.py command so that the script can successfully exist once the service is up and running? Should the script stop if one of the dependency fails to install, how to check that? Or the tests fail

sara-02 avatar Dec 12 '19 10:12 sara-02

@sara-02 my way of proving a good installation was to run the tests at the end of the installation procedure. It is possible to check the exit status of commands in bash, and display errors accordingly.

xprilion avatar Dec 12 '19 18:12 xprilion

Yes. I just added the comments to that anyone working on it now or in the future knows the gaps that need to be filled.

sara-02 avatar Dec 12 '19 18:12 sara-02

@isabelcosta @devkapilbansal do we need this still ?

vj-codes avatar Feb 20 '21 19:02 vj-codes