Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/node.js/34.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Node.js 在Heroku上安装节点curl_Node.js_Curl_Heroku_Dependencies_Npm - Fatal编程技术网

Node.js 在Heroku上安装节点curl

Node.js 在Heroku上安装节点curl,node.js,curl,heroku,dependencies,npm,Node.js,Curl,Heroku,Dependencies,Npm,完整免责声明这适用于我的本地机器Mac OSX 10.9.5。我已经使用npm安装在本地安装了该软件包。。。但是,当我推到heroku服务器时,会收到错误消息: gyp ERR! build error ... npm ERR! Failed at the node-curl@0.3.3 install script 'sh src/generate_curl_options_list.sh && (node-gyp rebuild || node-waf configure b

完整免责声明这适用于我的本地机器Mac OSX 10.9.5。我已经使用npm安装在本地安装了该软件包。。。但是,当我推到heroku服务器时,会收到错误消息:

gyp ERR! build error
...
npm ERR! Failed at the node-curl@0.3.3 install script 'sh src/generate_curl_options_list.sh && (node-gyp rebuild || node-waf configure build)'.
...
push rejected to yzx.xyz
当我在config.json中省略节点curl模块依赖项时,我能够推送:

"dependencies": {
        "node-curl": "0.3.3",
        ...
}
不幸的是,我的代码依赖于上述库:

var Curl = require('node-curl/lib/Curl');

可能与此有关,也可能与此有关。我的想法是运行ubuntu的heroku服务器与这个库或node curl的版本不兼容。在我的研究中,我还发现需要在主机上安装lib-curl包。有没有办法在Heroku上安装libcurl3 dev?或者我还可以尝试其他节点卷曲库吗?

结果表明我需要升级我的节点和npm引擎:

"engines": {
    "node": "0.8",
    "npm":"1.4.x"
  },

做了这个把戏

作为旁注,我最终使用了npm请求来满足我的所有需求。我来自PHP背景,所以CURL很有意义。原来我根本不需要卷发。