“在此服务器上找不到请求的URL /。” Heroku的/ Django的

时间:2015-04-06 22:42:56

标签: python django heroku

我正在尝试在Heroku上部署我的第一个Django应用程序,并且我正在关注Django Girls tutorial。它在当地运行良好。当我将它推送到Heroku时,我没有看到任何错误,他们的日志说“构建成功”,应用程序是“已部署”。当我去我的应用程序的网址时,我得到:

  

未找到

     

在此服务器上找不到请求的网址。

这是Heroku的构建日志:

-----> Python app detected
-----> Installing runtime (python-3.4.2)
-----> Installing dependencies with pip
       Collecting dj-database-url==0.3.0 (from -r requirements.txt (line 1))
         Downloading dj_database_url-0.3.0-py2.py3-none-any.whl
       Collecting Django==1.8 (from -r requirements.txt (line 2))
         Downloading Django-1.8-py2.py3-none-any.whl (6.2MB)
       Collecting gunicorn==19.3.0 (from -r requirements.txt (line 3))
         Downloading gunicorn-19.3.0-py2.py3-none-any.whl (110kB)
       Collecting whitenoise==1.0.6 (from -r requirements.txt (line 4))
         Downloading whitenoise-1.0.6-py2.py3-none-any.whl
       Collecting psycopg2==2.5.4 (from -r requirements.txt (line 5))
         Downloading psycopg2-2.5.4.tar.gz (682kB)
       Installing collected packages: psycopg2, whitenoise, gunicorn, Django, dj-database-url
         Running setup.py install for psycopg2
           building 'psycopg2._psycopg' extension
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/psycopgmodule.c -o build/temp.linux-x86_64-3.4/psycopg/psycopgmodule.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/green.c -o build/temp.linux-x86_64-3.4/psycopg/green.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/pqpath.c -o build/temp.linux-x86_64-3.4/psycopg/pqpath.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/utils.c -o build/temp.linux-x86_64-3.4/psycopg/utils.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/bytes_format.c -o build/temp.linux-x86_64-3.4/psycopg/bytes_format.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/connection_int.c -o build/temp.linux-x86_64-3.4/psycopg/connection_int.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/connection_type.c -o build/temp.linux-x86_64-3.4/psycopg/connection_type.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/cursor_int.c -o build/temp.linux-x86_64-3.4/psycopg/cursor_int.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/cursor_type.c -o build/temp.linux-x86_64-3.4/psycopg/cursor_type.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/diagnostics_type.c -o build/temp.linux-x86_64-3.4/psycopg/diagnostics_type.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/error_type.c -o build/temp.linux-x86_64-3.4/psycopg/error_type.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/lobject_int.c -o build/temp.linux-x86_64-3.4/psycopg/lobject_int.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/lobject_type.c -o build/temp.linux-x86_64-3.4/psycopg/lobject_type.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/notify_type.c -o build/temp.linux-x86_64-3.4/psycopg/notify_type.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/xid_type.c -o build/temp.linux-x86_64-3.4/psycopg/xid_type.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/adapter_asis.c -o build/temp.linux-x86_64-3.4/psycopg/adapter_asis.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/adapter_binary.c -o build/temp.linux-x86_64-3.4/psycopg/adapter_binary.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/adapter_datetime.c -o build/temp.linux-x86_64-3.4/psycopg/adapter_datetime.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/adapter_list.c -o build/temp.linux-x86_64-3.4/psycopg/adapter_list.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/adapter_pboolean.c -o build/temp.linux-x86_64-3.4/psycopg/adapter_pboolean.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/adapter_pdecimal.c -o build/temp.linux-x86_64-3.4/psycopg/adapter_pdecimal.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/adapter_pint.c -o build/temp.linux-x86_64-3.4/psycopg/adapter_pint.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/adapter_pfloat.c -o build/temp.linux-x86_64-3.4/psycopg/adapter_pfloat.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/adapter_qstring.c -o build/temp.linux-x86_64-3.4/psycopg/adapter_qstring.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/microprotocols.c -o build/temp.linux-x86_64-3.4/psycopg/microprotocols.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/microprotocols_proto.c -o build/temp.linux-x86_64-3.4/psycopg/microprotocols_proto.o -Wdeclaration-after-statement
           gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.4 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090306 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/app/.heroku/python/include/python3.4m -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.3/server -c psycopg/typecast.c -o build/temp.linux-x86_64-3.4/psycopg/typecast.o -Wdeclaration-after-statement
           gcc -pthread -shared build/temp.linux-x86_64-3.4/psycopg/psycopgmodule.o build/temp.linux-x86_64-3.4/psycopg/green.o build/temp.linux-x86_64-3.4/psycopg/pqpath.o build/temp.linux-x86_64-3.4/psycopg/utils.o build/temp.linux-x86_64-3.4/psycopg/bytes_format.o build/temp.linux-x86_64-3.4/psycopg/connection_int.o build/temp.linux-x86_64-3.4/psycopg/connection_type.o build/temp.linux-x86_64-3.4/psycopg/cursor_int.o build/temp.linux-x86_64-3.4/psycopg/cursor_type.o build/temp.linux-x86_64-3.4/psycopg/diagnostics_type.o build/temp.linux-x86_64-3.4/psycopg/error_type.o build/temp.linux-x86_64-3.4/psycopg/lobject_int.o build/temp.linux-x86_64-3.4/psycopg/lobject_type.o build/temp.linux-x86_64-3.4/psycopg/notify_type.o build/temp.linux-x86_64-3.4/psycopg/xid_type.o build/temp.linux-x86_64-3.4/psycopg/adapter_asis.o build/temp.linux-x86_64-3.4/psycopg/adapter_binary.o build/temp.linux-x86_64-3.4/psycopg/adapter_datetime.o build/temp.linux-x86_64-3.4/psycopg/adapter_list.o build/temp.linux-x86_64-3.4/psycopg/adapter_pboolean.o build/temp.linux-x86_64-3.4/psycopg/adapter_pdecimal.o build/temp.linux-x86_64-3.4/psycopg/adapter_pint.o build/temp.linux-x86_64-3.4/psycopg/adapter_pfloat.o build/temp.linux-x86_64-3.4/psycopg/adapter_qstring.o build/temp.linux-x86_64-3.4/psycopg/microprotocols.o build/temp.linux-x86_64-3.4/psycopg/microprotocols_proto.o build/temp.linux-x86_64-3.4/psycopg/typecast.o -L/app/.heroku/python/lib -L/usr/lib -lpython3.4m -lpq -o build/lib.linux-x86_64-3.4/psycopg2/_psycopg.cpython-34m.so




       Successfully installed Django-1.8 dj-database-url-0.3.0 gunicorn-19.3.0 psycopg2-2.5.4 whitenoise-1.0.6
-----> Preparing static assets
       Running collectstatic...
       62 static files copied to '/app/staticfiles'.
-----> Discovering process types
       Procfile declares types -> web
-----> Compressing... done, 49.0MB
-----> Launching... done, v5
       https://safe-beach-2834.herokuapp.com/ deployed to Heroku

此外,这里的输出来自: heroku logs --app safe-beach-2834

(myvenv) nicole (master) djangogirls $ heroku logs --app safe-beach-2834
2015-04-06T22:05:31.343987+00:00 heroku[api]: Enable Logplex by xxxxxx@gmail.com
2015-04-06T22:05:31.343987+00:00 heroku[api]: Release v2 created by xxxxxx@gmail.com
2015-04-06T22:12:22.322653+00:00 heroku[api]: Set DATABASE_URL config vars by xxxxxx@gmail.com
2015-04-06T22:12:22.322653+00:00 heroku[api]: Release v3 created by xxxxxx@gmail.com
2015-04-06T22:12:22.377377+00:00 heroku[api]: Attach HEROKU_POSTGRESQL_WHITE resource by xxxxxx@gmail.com
2015-04-06T22:12:22.377377+00:00 heroku[api]: Release v4 created by xxxxxx@gmail.com
2015-04-06T22:12:22.647369+00:00 heroku[api]: Scale to web=1 by xxxxxx@gmail.com
2015-04-06T22:12:22.741068+00:00 heroku[api]: Deploy 02a04d1 by xxxxxx@gmail.com
2015-04-06T22:12:22.741068+00:00 heroku[api]: Release v5 created by xxxxxx@gmail.com
2015-04-06T22:12:27.608326+00:00 heroku[web.1]: Starting process with command `gunicorn mysite.wsgi`
2015-04-06T22:12:29.808945+00:00 app[web.1]: [2015-04-06 22:12:29 +0000] [3] [INFO] Starting gunicorn 19.3.0
2015-04-06T22:12:29.880743+00:00 app[web.1]: [2015-04-06 22:12:29 +0000] [8] [INFO] Booting worker with pid: 8
2015-04-06T22:12:29.824097+00:00 app[web.1]: [2015-04-06 22:12:29 +0000] [7] [INFO] Booting worker with pid: 7
2015-04-06T22:12:29.813949+00:00 app[web.1]: [2015-04-06 22:12:29 +0000] [3] [INFO] Listening at: http://0.0.0.0:50470 (3)
2015-04-06T22:12:29.814055+00:00 app[web.1]: [2015-04-06 22:12:29 +0000] [3] [INFO] Using worker: sync
2015-04-06T22:12:31.333326+00:00 heroku[web.1]: State changed from starting to up
2015-04-06T22:12:41.548719+00:00 heroku[router]: at=info method=GET path="/" host=safe-beach-2834.herokuapp.com request_id=8feb77aa-3c2d-45a2-9e0d-4cde18378ca4 fwd="73.27.86.211" dyno=web.1 connect=0ms service=20ms status=404 bytes=274
2015-04-06T22:12:41.930108+00:00 heroku[router]: at=info method=GET path="/favicon.ico" host=safe-beach-2834.herokuapp.com request_id=042ce204-434a-402a-b6b0-4836d5757346 fwd="73.27.86.211" dyno=web.1 connect=1ms service=21ms status=404 bytes=285

我找到了一个有类似问题的人,但他们的原因是没有将一个模块添加到requirements.txt。我的所有模块都列好了,看起来安装没有错误。

看着这种代码对我来说是新的,所以我可能会在面前丢失一些东西。建议非常感谢。感谢。

urls.py:

from django.conf.urls import include, url

from django.contrib import admin

urlpatterns = [
    # Examples:
    # url(r'^$', 'mysite.views.home', name='home'),
    # url(r'^blog/', include('blog.urls')),

    url(r'^admin/', include(admin.site.urls)),
]

1 个答案:

答案 0 :(得分:6)

因为您的url(r'^$', 'path.to.function'),中没有url.py。这意味着您的网站没有网址/

我想当你打开像http://www.yourdomain.com/admin/这样的网址时,它正在运作,对吗?