[英]How to deploy nodejs and vuejs to heroku
我嘗試部署到 heroku,但總是出錯。
-----> App not compatible with buildpack: https://buildpack-registry.s3.amazonaws.com/buildpacks/heroku/nodejs.tgz
! ERROR: Application not supported by 'heroku/nodejs' buildpack
!
! The 'heroku/nodejs' buildpack is set on this application, but was
! unable to detect a Node.js codebase.
!
! A Node.js app on Heroku requires a 'package.json' at the root of
! the directory structure.
!
! If you are trying to deploy a Node.js application, ensure that this
! file is present at the top level directory. This directory has the
! following files:
!
! Procfile
! server/
! tsconfig.json
! vue/
!
! If you are trying to deploy an application written in another
! language, you need to change the list of buildpacks set on your
! Heroku app using the 'heroku buildpacks' command.
!
! For more information, refer to the following documentation:
! https://devcenter.heroku.com/articles/buildpacks
! https://devcenter.heroku.com/articles/nodejs-support#activation
More info: https://devcenter.heroku.com/articles/buildpacks#detection-failure
! Push failed
我可以更改 heroku 配置以使用子文件夾中的包文件嗎?
請根據其應用程序結構重構您的應用程序 Heroku 身份應用程序。
在您的root
目錄中沒有package.json
文件
最好將back-end
和front-end
部署為單獨的應用程序
希望這會幫助你。 快樂編碼。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.