I'm finishing with setting up my Django project on my hosting using ssh. i am following an article to be able to install it correctly. Some of the steps I had to follow are as follows:
Create the . htaccess file with the settings of the FCGI Handler and redirection to the index.fcgi file that will be created:
AddHandler fcgid-script .fcgi
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.fcgi/$1 [QSA,L]
and Create the index.fcgi file in the root of your application with the following content:
#!/home/CONTA/.virtualenv/bin/python
import os, sys
from flup.server.fcgi import WSGIServer
from django.core.wsgi import get_wsgi_application
sys.path.insert(0, "/home/CUENTA/mydjango")
os.environ['DJANGO_SETTINGS_MODULE'] = "mydjango.settings"
WSGIServer(get_wsgi_application()).run()
Already having those two files in the public html and opting the permissions to the index.fcgi using chmod 0755 At the time of me see if it is running using the following command ./index.fcgi, tells me that there is no file or directory.
Which leads me to assume that I need to set a path within the index.fcgi or . htaccess but I do not know what I need to change since in the article only comes that. Thank you