ein-dateien backend erstellt
This commit is contained in:
23
archiv/flask-backend/run.sh
Executable file
23
archiv/flask-backend/run.sh
Executable file
@@ -0,0 +1,23 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Initialize virtual environment if it doesn't exist
|
||||
if [ ! -d "venv" ]; then
|
||||
echo "Creating virtual environment..."
|
||||
python3 -m venv venv
|
||||
fi
|
||||
|
||||
# Activate virtual environment
|
||||
source venv/bin/activate
|
||||
|
||||
# Install dependencies
|
||||
echo "Installing dependencies..."
|
||||
pip install -r requirements.txt
|
||||
|
||||
# Initialize database
|
||||
echo "Initializing database..."
|
||||
flask db upgrade
|
||||
python scripts/init_db.py
|
||||
|
||||
# Run the application
|
||||
echo "Starting Flask application..."
|
||||
python wsgi.py
|
||||
Reference in New Issue
Block a user