2017-01-19 7 views
0

Watson IoTPボイラープレートアプリケーションをDiegoに移行した後、起動しなくなりました。ログに次のように表示されます:Diego移行後にIoTPボイラープレートアプリケーションが動作しない

[APP/0]  OUT Welcome to Node-RED 
[APP/0]  OUT =================== 
[APP/0]  OUT 18 Jan 15:43:16 - [info] Node-RED version: v0.15.3 
[APP/0]  OUT 18 Jan 15:43:16 - [info] Node.js version: v4.6.2 
[APP/0]  OUT 18 Jan 15:43:16 - [info] Linux 4.4.0-45-generic x64 LE 
[APP/0]  OUT 18 Jan 15:43:16 - [info] Loading palette nodes 
[APP/0]  OUT 18 Jan 15:43:18 - [warn] [ibm hdfs in] Deprecated call to RED.runtime.nodes.registerType - node-set name must be provided as first argument 
[APP/0]  OUT 18 Jan 15:43:18 - [warn] [ibm hdfs] Deprecated call to RED.runtime.nodes.registerType - node-set name must be provided as first argument 
[APP/0]  OUT 18 Jan 15:43:18 - [warn] [ibmpush] Deprecated call to RED.runtime.nodes.registerType - node-set name must be provided as first argument 
[APP/0]  OUT 18 Jan 15:43:20 - [info] Settings file : /home/vcap/app/bluemix-settings.js 
[APP/0]  OUT 18 Jan 15:43:20 - [info] Server now running at http://127.0.0.1:`**1880**`/red/ 
[APP/0]  OUT 18 Jan 15:43:20 - [info] Starting flows 
[APP/0]  OUT 18 Jan 15:43:20 - [info] Started flows 
[CELL/0]  ERR Timed out after 1m0s: health check never passed. 
[CELL/0]  OUT Exit status 0 
[CELL/0]  OUT Destroying container 
[API/8]  OUT App instance exited with guid ca3f2bbd-ac6e-42ec-8a61-1ff704274c3e payload: {"instance"=>"", "index"=>0, "reason"=>"CRASHED", "exit_description"=>"2 error(s) occurred:\n\n* 1 error(s) occurred:\n\n* Exited with status 4\n* 2 error(s) occurred:\n\n* cancelled\n* process did not exit", "crash_count"=>2, "crash_timestamp"=>1484754267594231230, "version"=>"0361fa77-694c-4e8f-991e-0c52dd0c4c87"} 

どうすればこの問題を解決できますか?

答えて

3

問題は、アプリがバインドするポートを見つける方法がDiegoと変わったということです。 VCAP_APP_PORT環境変数はデフォルトでは設定されなくなりました。これを修正するには、アプリのgit repoを作成する必要があります([概要]タブ - > [継続配信]> [GITを追加])。

uiPortにprocess.env.VCAP_APP_PORT

uiPortを変更するbluemix-settings.jsファイルを編集するjazzhubを使用しprocess.env.PORT

は、それらの変更やアプリを展開します開始する必要があります。

+0

ありがとう@alexandrakayy、それは私のためにそれを修正 –

0

私は、npm expressのアプリケーションで同様の問題があり、bluemix-settings.jsファイルを編集することなく修正しました。

シンプルであれば、process.env.VCAP_APP_HOST(Diegoのリファレンスは不要)への参照をすべて削除し、process.env.VCAP_APP_PORTをprocess.env.PORTに変更します。例えば

var host = 'localhost'; 
var port = (process.env.PORT || 1337); 
app.listen(port, host); 
console.log('App started on port ' + port); 

あなたが入力することによって、あなたのアプリがサンディエゴを実行しているかどうかを確認することができます

cf has-diego-enabled APPNAME 

を私も

cf install-plugin Diego-Enabler -r CF-Community 

ディエゴCLIツールをインストールした後、無効な健康診断:

cf set-health-check APPNAME none 
関連する問題