Skip to content

Instantly share code, notes, and snippets.

@danbjoseph
Last active August 29, 2015 14:19
Show Gist options
  • Save danbjoseph/6fb39ae979b8e87c55d8 to your computer and use it in GitHub Desktop.
Save danbjoseph/6fb39ae979b8e87c55d8 to your computer and use it in GitHub Desktop.
osm-meta-api install
cd /
sudo wget http://nodejs.org/dist/v0.12.2/node-v0.12.2-linux-x64.tar.gz
sudo tar -C /usr/local --strip-components 1 -xzf node-v0.12.2-linux-x64.tar.gz
node -v
npm -v
sudo npm install pm2 -g
sudo add-apt-repository ppa:git-core/ppa
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install git
git --version
sudo apt-get install oracle-java7-installer
java -version
sudo apt-get install build-essential
wget -qO - https://packages.elasticsearch.org/GPG-KEY-elasticsearch | sudo apt-key add -
echo "deb http://packages.elasticsearch.org/elasticsearch/1.5/debian stable main" | sudo tee -a /etc/apt/sources.list
sudo apt-get update && sudo apt-get install elasticsearch
sudo update-rc.d elasticsearch defaults 95 10
sudo /etc/init.d/elasticsearch start
export ES_SERVER="http://localhost:9200"
sudo git clone https://github.com/osmlab/osm-meta-api.git
cd osm-meta-api
npm install
node bootstrap.js
pm2 start app.js
sudo apt-get update
sudo apt-get install screen
https://www.digitalocean.com/community/tutorials/how-to-install-and-use-screen-on-an-ubuntu-cloud-server
@danbjoseph
Copy link
Author

ubuntu@ip-172-31-36-248:/osm-meta-api$ sudo npm install
npm WARN engine elasticsearch@3.1.3: wanted: {"node":">=0.8 <0.11"} (current: {"node":"0.12.2","npm":"2.7.4"})
npm WARN deprecated grunt-lib-contrib@0.7.1: DEPRECATED. See readme: https://github.com/gruntjs/grunt-lib-contrib

> sails@0.11.0 preinstall /osm-meta-api/node_modules/sails
> node ./lib/preinstall_npmcheck.js

Sails.js Installation: Checking npm-version successful

> iconv@2.1.6 install /osm-meta-api/node_modules/osm-meta-util/node_modules/node-expat/node_modules/iconv
> node-gyp rebuild

gyp ERR! build error 
gyp ERR! stack Error: not found: make
gyp ERR! stack     at F (/usr/local/lib/node_modules/npm/node_modules/which/which.js:40:28)
gyp ERR! stack     at E (/usr/local/lib/node_modules/npm/node_modules/which/which.js:43:29)
gyp ERR! stack     at /usr/local/lib/node_modules/npm/node_modules/which/which.js:54:16
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:95:15)
gyp ERR! System Linux 3.13.0-48-generic
gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /osm-meta-api/node_modules/osm-meta-util/node_modules/node-expat/node_modules/iconv
gyp ERR! node -v v0.12.2
gyp ERR! node-gyp -v v1.0.3
gyp ERR! not ok 
npm WARN deprecated node-switchback@0.0.4: The 'node-switchback' NPM module is now simply 'switchback'. See https://github.com/node-machine/switchback for latest docs.
npm WARN deprecated node-switchback@0.0.2: The 'node-switchback' NPM module is now simply 'switchback'. See https://github.com/node-machine/switchback for latest docs.

> ws@0.5.0 install /osm-meta-api/node_modules/sails/node_modules/sails-hook-sockets/node_modules/socket.io/node_modules/engine.io/node_modules/ws
> (node-gyp rebuild 2> builderror.log) || (exit 0)

/
> ws@0.4.31 install /osm-meta-api/node_modules/sails/node_modules/sails-hook-sockets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws
> (node-gyp rebuild 2> builderror.log) || (exit 0)

npm ERR! Linux 3.13.0-48-generic
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install"
npm ERR! node v0.12.2
npm ERR! npm  v2.7.4
npm ERR! code ELIFECYCLE

npm ERR! iconv@2.1.6 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the iconv@2.1.6 install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the iconv package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get their info via:
npm ERR!     npm owner ls iconv
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /osm-meta-api/npm-debug.log

@dalekunce
Copy link

yeah, you shouldn't have to sudo npm install. I think you need to chown and chmod the folder

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment