私は Godaddy でデラックスな Linux ホスティング アカウントを持っており、過去 3 日間から Django Web サイトをホストしようとしています。
私はこれらのチュートリアルに従いました:
http://www.lichun.cc/blog/2012/06/setup-django-1-4-on-godaddy-linux-economy-host/
http://blurback.com/post/563604002/running-django-on-godaddy-sigh
しかし、私はこれを得ています:
禁断
このサーバーの / にアクセスする権限がありません。
さらに、ErrorDocument を使用して要求を処理しようとしたときに、404 Not Found エラーが発生しました。
www.gccfishing.com の Apache サーバー ポート 80
問題は、 files: の最初の行に記述されている python パスにあると思います。SSH でファイル#!/usr/local/bin/python2.7
を実行しようとすると、次のエラーが発生するためです。
-bash: ./test.py: /usr/local/bin/python2.7^M: bad interpreter: No such file or directory.
ここで、test.py はサンプル テスト ファイルであり、chmod されています。
これは、godaddy での私のフォルダー構成です。
home
content
88
10907688
.pip
data
error_logs
html
lib
scctmp
tmp
html
上記のチュートリアルに従って、dispatch.py または .cgi ファイルのいずれかのファイルを配置しています。
私はlib
次のものを持っています:
venv
bin
gccFishing (this is the Django project)
MySQLdb
python ( file type: File)
python2.7 ( file type: 7 File)
django-admin.py
acitvate_this.py
include
shortcut folder of python2.7
lib
python2.7
shortcuts to all python libraries
site-packages(this is where I downloaded Django)
ここで何が起こっているか分かりますか?
Apache が最初に実行するファイルは?
dispatch.py または dispatch.cgi を使用する必要がありますか?
ヘルプ/コメントは非常に役立ちます。ありがとうございました。