GitXplorerGitXplorer
c

openshift-node-diy

public
6 stars
2 forks
0 issues

Commits

List of commits on branch master.
Unverified
8c904cc35541202bad8b1757c132cd3c59afa1cf

update versions

committed 10 years ago
Unverified
006cc977ac835f6b5b7e8d58c3528e11e7015c3e

Update README.md

cconnyay committed 10 years ago
Unverified
90d4578b5514808986e2bfbf7c9d1eab5e8f95fc

Update README.md

cconnyay committed 10 years ago
Unverified
142fbaa8f3f69cb865d62b981f73e1a41a6fde76

Update manifest.yml

cconnyay committed 10 years ago
Unverified
cbd9671cc6222699dd7d6dfe6cbb8da5b9133fcf

Update README.md

cconnyay committed 10 years ago
Unverified
6f0c9efc1b78dca0e29c413e1e690eb6cb9e96a8

update manifest

cconnyay committed 10 years ago

README

The README file for this repository.

Openshift Node DIY

Usage

rhc create-app <app name> http://tinyurl.com/OpenShiftNodeDIY

What this cartridge provides out of the box

  1. node.js (latest stable currently 0.10.35)
  2. npm (latest stable currently 1.4.28)
  3. grunt
  4. bower

What this cartridge does out of the box

Not much.

  1. Installs node.js (version specified by $OPENSHIFT_NODEJS_VERSION and resolved by semver.io)
  2. Installs grunt, bower, and forever globally (specified by $OPENSHIFT_NPM_GLOBALS)
  3. Allows the user to manually install required dependencies (in a build action_hook)
  4. Runs npm start if package.json is found in repo directory (log is written to $OPENSHIFT_NODEJS_LOG_DIR)

How can I modify the cartridge

Use a different version of node
(using 0.11.13 as an example)
  1. Run rhc env set OPENSHIFT_NODEJS_CUSTOM_VERSION="0.11.13" -a <app name>
  2. Run rhc cartridge reload http://tinyurl.com/OpenShiftNodeDIY -a <app name>

Heads up! The cartridge defaults to installing grunt, bower, and forever globally. Bower depends on node >=0.10.0. If you wish to use an older version of node set $OPENSHIFT_NPM_CUSTOM_GLOBALS to not include bower.

Install more npm packages globally
(using gulp and component as an example)
  1. Run rhc env set OPENSHIFT_NPM_CUSTOM_GLOBALS="gulp component" -a <app name>
  2. Run rhc cartridge reload http://tinyurl.com/OpenShiftNodeDIY -a <app name>

Thanks!

These repos helped out a ton while developing this cartridge.

  1. engineersamuel/openshift-origin-cartridge-nodejs
  2. wshearn/openshift-origin-cartridge-nodejs
  3. ramr/nodejs-custom-version-openshift
  4. heroku/heroku-buildpack-nodejs