21 lines
531 B
Bash
21 lines
531 B
Bash
#!/bin/bash
|
|
|
|
# Exit immediately if a command exits with a non-zero status
|
|
set -e
|
|
|
|
# Activate the virtual environment
|
|
source venv/bin/activate
|
|
|
|
# Run the Gunicorn server in the foreground
|
|
echo "Starting Gunicorn server..."
|
|
exec python3 app.py &
|
|
|
|
# Wait for 5 seconds to ensure the server is up
|
|
sleep 8
|
|
|
|
# Launch Chromium in fullscreen and kiosk mode
|
|
echo "Launching Chromium in fullscreen and kiosk mode..."
|
|
chromium-browser --kiosk --start-fullscreen http://localhost:1025
|
|
|
|
# Deactivate the virtual environment when done
|
|
deactivate |