코딩공부/Python Django

heroku ModuleNotFoundError: No module named 'app.wsgi'

integerJI 2020. 7. 31. 12:58

An error occurred in the application and your page could not be served. 
If you are the application owner, check your logs for details. 
You can do this from the Heroku CLI with the command

heroku logs --tail
at=error code=H10 desc="App crashed" ...생략 dyno= connect= service= status=503 bytes= protocol=https

 

heroku open을 하니 위의 오류가 나왔습니다.

 

heroku logs --tail을 입력하여 로그를 보니

 

ModuleNotFoundError: No module named 'app.wsgi' 가 나왔습니다.

 

해당 오류는 wsgi에서 오류가 난건데 wsgi 하니까 생각난게

 

 

바로 Procfile 였습니다...

 

알고보니까 이곳에

web: gunicorn <<project>>.wsgi --log-file -

 

로 project를 입력해준게아니라 App이름을 입력했더라구요 ;;;

 

수정후 커밋 하니 정상으로 출력 되었습니다.