Skip to content

Instantly share code, notes, and snippets.

@avimar
Created July 11, 2012 19:37
Show Gist options
  • Star 7 You must be signed in to star a gist
  • Fork 5 You must be signed in to fork a gist
  • Save avimar/3092732 to your computer and use it in GitHub Desktop.
Save avimar/3092732 to your computer and use it in GitHub Desktop.
install node.js from source with salt
nodejs-deps:
pkg.installed:
- names:
- g++
- curl
- libssl-dev
- apache2-utils
require:
- pkg: git
nodejs-source:
git.latest:
- target: /usr/src/nodejs
- name: git://github.com/joyent/node.git
- rev: v0.8.4-release
nodejs-install:
cmd.run:
- cwd: /usr/src/nodejs
- name: ./configure && make && make install
- onlyif: if [ -z $(node --version) ] || [ $(node --version) != "v0.8.4" ]; then echo "should update"; else exit 1; fi;
- require:
- git: nodejs-source
- pkg: nodejs-deps
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment