import os
import sys

# Add the project root directory to the python path
sys.path.insert(0, os.path.dirname(__file__))

# Add cPanel virtualenv site-packages to python path (fallback if cPanel fails to load it)
venv_path = '/home/jtprope5/virtualenv/ramisatrade.com/3.10/lib/python3.10/site-packages'
if os.path.exists(venv_path):
    sys.path.insert(0, venv_path)

# Import the Flask instance 'app' as 'application' (Phusion Passenger expects this name)
from app import app as application
