Openshift 上的自定义 node.js 版本

Custom node.js version on Openshift

我遇到问题 运行在 node0.10 盒式磁带上使用自定义节点版本打开轮班,您可以找到 here

我安装新节点版本非常好,但是 open shift 继续使用旧节点 10.25

部署日志:

remote: Activating deployment
remote:   - Checking to see if Node.js version 0.10.33 is installed ... 
remote:   - Node.js version 0.10.33 is already installed
remote: 
remote:   - pre_start_nodejs: Adding Node.js version 0.10.33 binaries to path
remote: -this is the path: /var/lib/openshift/54b6ea6e4382ece151000039/app-root/data/node-v0.10.33-linux-x64/bin:/var/lib/openshift/54b6ea6e4382ece151000039/app-root/runtime/repo/node_modules/.bin:/var/lib/openshift/54b6ea6e4382ece151000039//.node_modules/.bin:/opt/rh/nodejs010/root/usr/bin:/bin:/usr/bin:/usr/sbin 
remote:   - PATH set to include custom node version (0.10.33) from
remote:        /var/lib/openshift/54b6ea6e4382ece151000039/app-root/data/node-v0.10.33-linux-x64/bin 
remote:     PATH = /var/lib/openshift/54b6ea6e4382ece151000039/app-root/data/node-v0.10.33-linux-x64/bin:/var/lib/openshift/54b6ea6e4382ece151000039/app-root/runtime/repo/node_modules/.bin:/var/lib/openshift/54b6ea6e4382ece151000039//.node_modules/.bin:/opt/rh/nodejs010/root/usr/bin:/bin:/usr/bin:/usr/sbin
remote: Starting NodeJS cartridge

一切看起来都很棒很棒,直到我 运行 应用程序显示:10.25...

rhc 尾部:

v0.10.25

/opt/rh/nodejs010/root/usr/bin:/opt/rh/v8314/root/usr/bin:/var/lib/openshift/54b6feb9e0b8cd56c00000e1/app-root/data/node-v0.10.33-linux-x64/bin:/var/lib/openshift/54b6feb9e0b8cd56c00000e1/app-root/runtime/repo/node_modules/.bin:/var/lib/openshift/54b6feb9e0b8cd56c00000e1//.node_modules/.bin:/opt/rh/nodejs010/root/usr/bin:/bin:/usr/bin:/usr/sbin

undefined

即使我 rhc ssh 到我的应用程序并尝试 node -v 我得到 10.33...

在开始时,PATH env 被覆盖并导致节点使用旧的 bins...

PS: 我正在尝试部署 Meteor 应用程序 (1.0.2.1)

没关系,想通了:-)

如果您想使用自定义节点@openshift,请查看this repo

希望我能帮到别人!