generated from hack4impact/flask-base
-
-
Notifications
You must be signed in to change notification settings - Fork 174
Developer Information
SelfhostedPro edited this page Sep 16, 2020
·
2 revisions
This assumes you're using vscode and will want to use the debugging tools for the backend. If you're not using vscode then skip the launch.json section.
git clone https://github.com/SelfhostedPro/Yacht.git
Checkout the vue branch and make a config directory for the db:
cd Yacht
git checkout vue
mkdir config
cd backend
python -m venv venv
source venv/bin/activate
pip install -r requirements.txt
Install the frontend requirements:
cd ../frontend
npm install
in the root directory create a .vscode folder and paste the following launch.json:
cd ..
mkdir .vscode
nano launch.json
{
"configurations": [
{
"name": "Python: Module",
"type": "python",
"request": "launch",
"module": "uvicorn",
"args": [
"backend.api.main:app",
"--reload"
]
}
]
}
Start the backend using the run button in the debugging tab in vscode or manually run it. Then for the frontend run the following from inside the frontend folder:
npm run serve
Here is an untested script that basically combines everything except for the launch.json stuff:
#!/bin/bash
git clone https://github.com/SelfhostedPro/Yacht.git
cd Yacht
git checkout vue
mkdir config
cd backend
python -m venv venv
source venv/bin/activate
pip install -r requirements.txt
cd ../frontend
npm install
Then just use the "Run Everything section above