heroku.com是一个提供支持nodejs,mongodb的虚拟主机服务的网站,还能和github,dropbox等绑定发布,很好用。尤其是作为学习阶段来说更是不错。
但是本人将thinkjs发布到heroku上时遇到无法启用的问题。大牛能写个发布步骤吗?
谢谢了!
扫码关注w3ctech微信公众号
-----> Node.js app detected -----> Reading application state package.json... build directory... cache directory... environment variables... Node engine: >=0.10.0 Npm engine: unspecified Start mechanism: Procfile node_modules source: package.json node_modules cached: true NPM_CONFIG_PRODUCTION=true NODE_MODULES_CACHE=true -----> Installing binaries Resolving node version >=0.10.0 via semver.io... Downloading and installing node 0.12.3... Using default npm version: 2.9.1 -----> Building dependencies Restoring node modules from cache Pruning unused dependencies unbuild harp@0.17.0 valid Installing node modules thinkjs@1.2.3 node_modules/thinkjs ????????? mime@1.2.11 ????????? es6-promise@2.0.1 ????????? thinkjs-util@1.1.2 (es6-promise@2.0.0) ????????? websocket-driver@0.5.3 (websocket-extensions@0.1.1) ????????? ejs@2.2.4 ????????? multiparty@4.1.1 (fd-slicer@1.0.1) ????????? mysql@2.5.4 (require-all@0.0.8, bignumber.js@1.4.1, readable-stream@1.1.13) -----> Checking startup method Found Procfile -----> Finalizing build Creating runtime environment Exporting binary paths Cleaning npm artifacts Cleaning previous cache Caching results for future builds -----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Node.js app detected -----> Reading application state package.json... build directory... cache directory... environment variables... Node engine: >=0.10.0 Npm engine: unspecified Start mechanism: Procfile node_modules source: package.json node_modules cached: true NPM_CONFIG_PRODUCTION=true NODE_MODULES_CACHE=true -----> Installing binaries Resolving node version >=0.10.0 via semver.io... Downloading and installing node 0.12.3... Using default npm version: 2.9.1 -----> Building dependencies Restoring node modules from cache Pruning unused dependencies unbuild harp@0.17.0 valid Installing node modules thinkjs@1.2.3 node_modules/thinkjs ????????? mime@1.2.11 ????????? es6-promise@2.0.1 ????????? thinkjs-util@1.1.2 (es6-promise@2.0.0) ????????? websocket-driver@0.5.3 (websocket-extensions@0.1.1) ????????? ejs@2.2.4 ????????? multiparty@4.1.1 (fd-slicer@1.0.1) ????????? mysql@2.5.4 (require-all@0.0.8, bignumber.js@1.4.1, readable-stream@1.1.13) -----> Checking startup method Found Procfile -----> Finalizing build Creating runtime environment Exporting binary paths Cleaning npm artifacts Cleaning previous cache Caching results for future builds -----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Node.js app detected -----> Reading application state package.json... build directory... cache directory... environment variables... Node engine: >=0.10.0 Npm engine: unspecified Start mechanism: Procfile node_modules source: package.json node_modules cached: true NPM_CONFIG_PRODUCTION=true NODE_MODULES_CACHE=true -----> Installing binaries Resolving node version >=0.10.0 via semver.io... Downloading and installing node 0.12.3... Using default npm version: 2.9.1 -----> Building dependencies Restoring node modules from cache Pruning unused dependencies unbuild harp@0.17.0 valid Installing node modules thinkjs@1.2.3 node_modules/thinkjs ????????? mime@1.2.11 ????????? es6-promise@2.0.1 ????????? thinkjs-util@1.1.2 (es6-promise@2.0.0) ????????? websocket-driver@0.5.3 (websocket-extensions@0.1.1) ????????? ejs@2.2.4 ????????? multiparty@4.1.1 (fd-slicer@1.0.1) ????????? mysql@2.5.4 (require-all@0.0.8, bignumber.js@1.4.1, readable-stream@1.1.13) -----> Checking startup method Found Procfile -----> Finalizing build Creating runtime environment Exporting binary paths Cleaning npm artifacts Cleaning previous cache Caching results for future builds -----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Node.js app detected -----> Reading application state package.json... build directory... cache directory... environment variables... Node engine: >=0.10.0 Npm engine: unspecified Start mechanism: Procfile node_modules source: package.json node_modules cached: true NPM_CONFIG_PRODUCTION=true NODE_MODULES_CACHE=true -----> Installing binaries Resolving node version >=0.10.0 via semver.io... Downloading and installing node 0.12.3... Using default npm version: 2.9.1 -----> Building dependencies Restoring node modules from cache Pruning unused dependencies unbuild harp@0.17.0 valid Installing node modules thinkjs@1.2.3 node_modules/thinkjs ????????? mime@1.2.11 ????????? es6-promise@2.0.1 ????????? thinkjs-util@1.1.2 (es6-promise@2.0.0) ????????? websocket-driver@0.5.3 (websocket-extensions@0.1.1) ????????? ejs@2.2.4 ????????? multiparty@4.1.1 (fd-slicer@1.0.1) ????????? mysql@2.5.4 (require-all@0.0.8, bignumber.js@1.4.1, readable-stream@1.1.13) -----> Checking startup method Found Procfile -----> Finalizing build Creating runtime environment Exporting binary paths Cleaning npm artifacts Cleaning previous cache Caching results for future builds -----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Node.js app detected -----> Reading application state package.json... build directory... cache directory... environment variables... Node engine: >=0.10.0 Npm engine: unspecified Start mechanism: Procfile node_modules source: package.json node_modules cached: true NPM_CONFIG_PRODUCTION=true NODE_MODULES_CACHE=true -----> Installing binaries Resolving node version >=0.10.0 via semver.io... Downloading and installing node 0.12.3... Using default npm version: 2.9.1 -----> Building dependencies Restoring node modules from cache Pruning unused dependencies unbuild harp@0.17.0 valid Installing node modules thinkjs@1.2.3 node_modules/thinkjs ????????? mime@1.2.11 ????????? es6-promise@2.0.1 ????????? thinkjs-util@1.1.2 (es6-promise@2.0.0) ????????? websocket-driver@0.5.3 (websocket-extensions@0.1.1) ????????? ejs@2.2.4 ????????? multiparty@4.1.1 (fd-slicer@1.0.1) ????????? mysql@2.5.4 (require-all@0.0.8, bignumber.js@1.4.1, readable-stream@1.1.13) -----> Checking startup method Found Procfile -----> Finalizing build Creating runtime environment Exporting binary paths Cleaning npm artifacts Cleaning previous cache Caching results for future builds -----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Node.js app detected -----> Reading application state package.json... build directory... cache directory... environment variables... Node engine: >=0.10.0 Npm engine: unspecified Start mechanism: Procfile node_modules source: package.json node_modules cached: true NPM_CONFIG_PRODUCTION=true NODE_MODULES_CACHE=true -----> Installing binaries Resolving node version >=0.10.0 via semver.io... Downloading and installing node 0.12.3... Using default npm version: 2.9.1 -----> Building dependencies Restoring node modules from cache Pruning unused dependencies unbuild harp@0.17.0 valid Installing node modules thinkjs@1.2.3 node_modules/thinkjs ????????? mime@1.2.11 ????????? es6-promise@2.0.1 ????????? thinkjs-util@1.1.2 (es6-promise@2.0.0) ????????? websocket-driver@0.5.3 (websocket-extensions@0.1.1) ????????? ejs@2.2.4 ????????? multiparty@4.1.1 (fd-slicer@1.0.1) ????????? mysql@2.5.4 (require-all@0.0.8, bignumber.js@1.4.1, readable-stream@1.1.13) -----> Checking startup method Found Procfile -----> Finalizing build Creating runtime environment Exporting binary paths Cleaning npm artifacts Cleaning previous cache Caching results for future builds -----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Node.js app detected -----> Reading application state package.json... build directory... cache directory... environment variables... Node engine: >=0.10.0 Npm engine: unspecified Start mechanism: Procfile node_modules source: package.json node_modules cached: true NPM_CONFIG_PRODUCTION=true NODE_MODULES_CACHE=true -----> Installing binaries Resolving node version >=0.10.0 via semver.io... Downloading and installing node 0.12.3... Using default npm version: 2.9.1 -----> Building dependencies Restoring node modules from cache Pruning unused dependencies unbuild harp@0.17.0 valid Installing node modules thinkjs@1.2.3 node_modules/thinkjs ????????? mime@1.2.11 ????????? es6-promise@2.0.1 ????????? thinkjs-util@1.1.2 (es6-promise@2.0.0) ????????? websocket-driver@0.5.3 (websocket-extensions@0.1.1) ????????? ejs@2.2.4 ????????? multiparty@4.1.1 (fd-slicer@1.0.1) ????????? mysql@2.5.4 (require-all@0.0.8, bignumber.js@1.4.1, readable-stream@1.1.13) -----> Checking startup method Found Procfile -----> Finalizing build Creating runtime environment Exporting binary paths Cleaning npm artifacts Cleaning previous cache Caching results for future builds -----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Node.js app detected -----> Reading application state package.json... build directory... cache directory... environment variables... Node engine: >=0.10.0 Npm engine: unspecified Start mechanism: Procfile node_modules source: package.json node_modules cached: true NPM_CONFIG_PRODUCTION=true NODE_MODULES_CACHE=true -----> Installing binaries Resolving node version >=0.10.0 via semver.io... Downloading and installing node 0.12.3... Using default npm version: 2.9.1 -----> Building dependencies Restoring node modules from cache Pruning unused dependencies unbuild harp@0.17.0 valid Installing node modules thinkjs@1.2.3 node_modules/thinkjs ????????? mime@1.2.11 ????????? es6-promise@2.0.1 ????????? thinkjs-util@1.1.2 (es6-promise@2.0.0) ????????? websocket-driver@0.5.3 (websocket-extensions@0.1.1) ????????? ejs@2.2.4 ????????? multiparty@4.1.1 (fd-slicer@1.0.1) ????????? mysql@2.5.4 (require-all@0.0.8, bignumber.js@1.4.1, readable-stream@1.1.13) -----> Checking startup method Found Procfile -----> Finalizing build Creating runtime environment Exporting binary paths Cleaning npm artifacts Cleaning previous cache Caching results for future builds -----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Node.js app detected -----> Reading application state package.json... build directory... cache directory... environment variables... Node engine: >=0.10.0 Npm engine: unspecified Start mechanism: Procfile node_modules source: package.json node_modules cached: true NPM_CONFIG_PRODUCTION=true NODE_MODULES_CACHE=true -----> Installing binaries Resolving node version >=0.10.0 via semver.io... Downloading and installing node 0.12.3... Using default npm version: 2.9.1 -----> Building dependencies Restoring node modules from cache Pruning unused dependencies unbuild harp@0.17.0 valid Installing node modules thinkjs@1.2.3 node_modules/thinkjs ????????? mime@1.2.11 ????????? es6-promise@2.0.1 ????????? thinkjs-util@1.1.2 (es6-promise@2.0.0) ????????? websocket-driver@0.5.3 (websocket-extensions@0.1.1) ????????? ejs@2.2.4 ????????? multiparty@4.1.1 (fd-slicer@1.0.1) ????????? mysql@2.5.4 (require-all@0.0.8, bignumber.js@1.4.1, readable-stream@1.1.13) -----> Checking startup method Found Procfile -----> Finalizing build Creating runtime environment Exporting binary paths Cleaning npm artifacts Cleaning previous cache Caching results for future builds -----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Node.js app detected -----> Reading application state package.json... build directory... cache directory... environment variables... Node engine: >=0.10.0 Npm engine: unspecified Start mechanism: Procfile node_modules source: package.json node_modules cached: true NPM_CONFIG_PRODUCTION=true NODE_MODULES_CACHE=true -----> Installing binaries Resolving node version >=0.10.0 via semver.io... Downloading and installing node 0.12.3... Using default npm version: 2.9.1 -----> Building dependencies Restoring node modules from cache Pruning unused dependencies unbuild harp@0.17.0 valid Installing node modules thinkjs@1.2.3 node_modules/thinkjs ????????? mime@1.2.11 ????????? es6-promise@2.0.1 ????????? thinkjs-util@1.1.2 (es6-promise@2.0.0) ????????? websocket-driver@0.5.3 (websocket-extensions@0.1.1) ????????? ejs@2.2.4 ????????? multiparty@4.1.1 (fd-slicer@1.0.1) ????????? mysql@2.5.4 (require-all@0.0.8, bignumber.js@1.4.1, readable-stream@1.1.13) -----> Checking startup method Found Procfile -----> Finalizing build Creating runtime environment Exporting binary paths Cleaning npm artifacts Cleaning previous cache Caching results for future builds -----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Build succeeded! project-name@0.1.0 /tmp/build_db6e39e06ca3f5e4a422fc5397e3b693/flyingliu-yugea-8e5ee15 ????????? thinkjs@1.2.3
-----> Discovering process types Procfile declares types -> web -----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
-----> Compressing... done, 9.9MB -----> Launching... done, v21 https://yuge.herokuapp.com/ deployed to Heroku
你直接把报错贴在 正文中,多好呀,而且前后加上 ```,让他作为代码展示。
@飞来小侠 你是怎么发布的呀,你在上面都npm install
上了吗?装thinkjs
了吗?
@裕波 我写下发布步骤: 1.新建启动命令文件:Procfile;内容为: ``` web: node www/index.js 2.更改配置文件端口,和关闭debug模式。 3.上传到github上。 4.在heroku.com上新建 app 5.选择Deploy,连接到github上thinkjs项目。 6.Deploy a GitHub branch 这样就显示了编译成功。在编译的时候会安装 thinkjs的。但是我不能正常访问。
以前我用harpjs的时候用这样的步骤是可以的,他会根据package.json安装依赖包的。 我的QQ是:63480013,可以Q我交流。
共收到22条回复