Dear All
I just learn to deploy simple python app on CPanel.
My system is alamalinux with CPanel.
The app is under virtual environment, just a single passenger to show 'helo world'.
here it is (passenger_wsgi.py)
When I open the site via web browser, looks like the passenger is 'called'.
But it show some error.
You can check it at REDACTED FOR SECURITY
Kindly please give me any clues to fix this problem
regards
-bino-
I just learn to deploy simple python app on CPanel.
My system is alamalinux with CPanel.
The app is under virtual environment, just a single passenger to show 'helo world'.
here it is (passenger_wsgi.py)
Python:
import sys, os
INTERP = "/home/binojcamp3/virtualenv/teluwolu/3.8/bin/python"
if sys.executable != INTERP: os.execl(INTERP, INTERP, *sys.argv)
cwd = os.getcwd()
sys.path.append(cwd)
sys.path.append(cwd + '/proj') #You must add your project here
sys.path.insert(0,cwd+'/virtualenv/teluwolu/3.8/bin')
sys.path.insert(0,cwd+'/virtualenv/teluwolu/3.8/lib/python3.8/site-packages')
def application(environ, start_response):
start_response('200 OK', [('Content-Type', 'text/plain')])
message = 'It works!\n'
version = 'Python %s\n' % sys.version.split()[0]
response = '\n'.join([message, version])
return [response.encode()]
When I open the site via web browser, looks like the passenger is 'called'.
But it show some error.
You can check it at REDACTED FOR SECURITY
Kindly please give me any clues to fix this problem
regards
-bino-
Last edited by a moderator: