-----> Building on the Heroku-20 stack
-----> Using buildpack: heroku/python
-----> Python app detected
-----> Using Python version specified in Pipfile.lock
-----> Requirements file has been changed, clearing cached dependencies
cp: cannot stat '/tmp/build_eaebc38f/requirements.txt': No such file or directory
-----> Installing python-3.10.2
-----> Installing pip 21.3.1, setuptools 57.5.0 and wheel 0.37.0
-----> Installing dependencies with Pipenv 2020.11.15
Installing dependencies from Pipfile.lock (86a10d)...
Ignoring tzdata: markers 'sys_platform == "win32"' don't match your environment
-----> Installing SQLite3
-----> $ python manage.py collectstatic --noinput
System check identified some issues:
WARNINGS:
?: (staticfiles.W004) The directory '/tmp/build_eaebc38f/static' in the STATICFILES_DIRS setting does not exist.
161 static files copied to '/tmp/build_eaebc38f/staticfiles', 414 post-processed.
-----> Discovering process types
Procfile declares types -> web
-----> Compressing...
Done: 98.7M
-----> Launching...
Released v11
https://vicsites.herokuapp.com/ deployed to Heroku这是我的heroku部署日志,它仍然显示应用程序错误。
这是我的过程文件
web: gunicorn vicsite.wsgi --log-file -我在上面提到的日志中发现的错误是:
?:(staticfiles.W004) STATICFILES_DIRS设置中的目录'/tmp/build_eaebc38f/static‘不存在。161个静态文件复制到'/tmp/build_eaebc38f/staticfiles',414个后处理文件。'sys_platform ==‘win32’与您的环境不匹配
我的项目迪尔
Mode LastWriteTime Length Name
---- ------------- ------ ----
d---- 3/11/2022 5:58 AM .vscode
d---- 3/12/2022 9:50 PM accounts
d---- 3/10/2022 6:43 AM investments
d---- 3/13/2022 9:06 PM site_server
d---- 3/14/2022 4:22 AM static
d---- 3/14/2022 4:25 AM staticfiles
d---- 3/10/2022 7:58 PM transactions
-a--- 3/13/2022 2:37 PM 23 .gitignore
-a--- 3/13/2022 2:43 PM 303104 db.sqlite3
-a--- 3/5/2022 2:55 PM 689 manage.py
-a--- 3/14/2022 4:58 AM 345 Pipfile
-a--- 3/14/2022 5:45 AM 29742 Pipfile.lock
-a--- 3/14/2022 11:10 AM 39 Procfile
-a--- 3/5/2022 2:43 PM 9 README.md发布于 2022-03-14 21:04:19
这个问题来自我的处理文件。我传递的是文件夹名(vicsite),而不是项目名(Site_server):
web: gunicorn vicsite.wsgi --log-file -
因此,正确的编写代码是:
web: gunicorn site_server.wsgi --log-file -
https://stackoverflow.com/questions/71463227
复制相似问题