一区二区三区日韩精品-日韩经典一区二区三区-五月激情综合丁香婷婷-欧美精品中文字幕专区

分享

mongodb kerberos peer dependency

 昵稱597197 2015-12-18

I just had to run npm install --save kerberos mongodb to successfully install mongodb in my project. I assume you can do it globally as well, but there may be other issues.

From the mongodb NPM package docs:

The kerberos package is a C++ extension that requires a build environment to be installed on your system. You must be able to build node.js itself to be able to compile and install the kerberos module. Furthermore the kerberos module requires the MIT Kerberos package to correctly compile on UNIX operating systems. Consult your UNIX operation system package manager what libraries to install.

It goes on to offer the following steps for diagnosing the issue on UNIX-based operating systems:

If you don’t have the build essentials it won’t build. In the case of linux you will need gcc and g++, node.js with all the headers and python. The easiest way to figure out what’s missing is by trying to build the kerberos project. You can do this by performing the following steps.

git clone https://github.com/christkv/kerberos.git
cd kerberos
npm install

If all the steps complete you have the right toolchain installed. If you get node-gyp not found you need to install it globally by doing.

npm install -g node-gyp

If correctly compiles and runs the tests you are golden. We can now try to install the mongod driver by performing the following command.

cd yourproject
npm install mongodb --save

If it still fails the next step is to examine the npm log. Rerun the command but in this case in verbose mode.

npm --loglevel verbose install mongodb

This will print out all the steps npm is performing while trying to install the module.

Other possible issues:

Your python installation might be hosed making gyp break. I always recommend that you test your deployment environment first by trying to build node itself on the server in question as this should unearth any issues with broken packages (and there are a lot of broken packages out there).

Another thing is to ensure your user has write permission to wherever the node modules are being installed.




#!/bin/bash
#My quasi bash script. This worked for Ubuntu v14.04 using Node.js v5.1.0 and mongodb v3.0.7
clear

# prerequisites for building node.js from its source files
sudo apt-get install clang-3.5 make gcc g++ libssl-dev libkrb5-dev

# where you extracted the latest stable release. https://github.com/nodejs/node/releases
cd ~/Downloads/node
# git clone https://github.com/nodejs/node # this does NOT work because it gets a beta/pre release.
./configure
# "-j 3" uses two processors for the compile on a duo core processor. 3 means 2 for some reason.
make -j 3
sudo make install
make doc
make test

# prerequisites for being able to use '$ npm install mongodb'
cd ~
sudo npm install -g node-gyp
sudo npm install -g kerberos

# npm mongodb will NOT install globally '-g'. Therefore you have to install local to each project.
#cd to/your/project/directory
# make sure you are in your project directory root and that the "node_modules" directory is not 'root:root'
npm install mongodb --save

    本站是提供個人知識管理的網(wǎng)絡(luò)存儲空間,所有內(nèi)容均由用戶發(fā)布,不代表本站觀點。請注意甄別內(nèi)容中的聯(lián)系方式、誘導(dǎo)購買等信息,謹(jǐn)防詐騙。如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請點擊一鍵舉報。
    轉(zhuǎn)藏 分享 獻(xiàn)花(0

    0條評論

    發(fā)表

    請遵守用戶 評論公約

    類似文章 更多

    九九热视频免费在线视频| 蜜桃传媒视频麻豆第一区| 久久国产青偷人人妻潘金莲| 国产av熟女一区二区三区蜜桃| 亚洲男女性生活免费视频| 九九热这里只有精品视频| 美国欧洲日本韩国二本道| 夫妻性生活一级黄色录像| 可以在线看的欧美黄片| 国产一区二区在线免费| 欧美日韩视频中文字幕| 精品日韩中文字幕视频在线| 99久久精品国产麻豆| 超薄丝袜足一区二区三区| 麻豆在线观看一区二区| 黄色激情视频中文字幕| 国产精品日韩精品一区| 国产精品香蕉一级免费| 伊人久久青草地婷婷综合| 高清在线精品一区二区| 午夜视频在线观看日韩| 久久香蕉综合网精品视频| 91麻豆视频国产一区二区| 亚洲一区二区三区在线中文字幕| 欧美成人免费夜夜黄啪啪| 高清一区二区三区大伊香蕉 | 冬爱琴音一区二区中文字幕| 青青操成人免费在线视频| 国产精品一区二区三区黄色片| 福利在线午夜绝顶三级| 久久精品亚洲精品国产欧美| 最新日韩精品一推荐日韩精品| 亚洲最新av在线观看| 又黄又硬又爽又色的视频| 午夜久久精品福利视频| 日本欧美一区二区三区在线播 | 91亚洲国产成人久久| 深夜福利亚洲高清性感| 丰满少妇被猛烈撞击在线视频| 国产精品免费视频视频| 小草少妇视频免费看视频|