-
文档
-
安装cURL
-
安装docker and docker compose
-
下载docker
-
安装docker
-
测试docker
-
-
安装Homebrew
-
官网
-
安装命令
-
-
Go programming Language
-
Node.js Runtime and NPM
-
安装nvm
-
安装过程
-
编辑.bash_profile,可以在终端使用nvm命令
-
.bash_profile添加如下代码
-
然后重新sourse
-
安装node的指定版本
-
-
文档
http://hyperledger-fabric.readthedocs.io/en/release/prereqs.html
安装cURL
Mac环境已经安装了curl
$ curl --version
curl 7.60.0 (x86_64-apple-darwin13.4.0) libcurl/7.60.0 OpenSSL/1.0.2o zlib/1.2.11
Release-Date: 2018-05-16
Protocols: dict file ftp ftps gopher http https imap imaps pop3 pop3s rtsp smb smbs smtp smtps telnet tftp
Features: AsynchDNS IPv6 Largefile NTLM NTLM_WB SSL libz TLS-SRP UnixSockets HTTPS-proxy
安装docker and docker compose
docker学习文档
菜鸟教程http://www.runoob.com/docker/docker-tutorial.html
下载docker
https://hub.docker.com/editions/community/docker-ce-desktop-mac
安装docker
测试docker
$docker —version
Docker version 18.09.2, build 6247962
$docker-compose —version
docker-compose version 1.23.2, build 1110ad01
安装Homebrew
官网
https://brew.sh/index_zh-cn.html
安装命令
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
Go Programming Language
$brew install go
Node.js Runtime and NPM
Node.js version 7.x is not supported at the time.
Node.js version 6.9.x or greater
fabric暂时不支持7.x,需要安装6.9.x或6.x高的版本,通过nvm安装指定版本的node
安装nvm
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.34.0/install.sh|bash
安装过程
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 13226 100 13226 0 0 1584 0 0:00:08 0:00:08 --:--:-- 1554
=> Downloading nvm from git to '/Users/xuwanxiang/.nvm'
=> Cloning into '/Users/xuwanxiang/.nvm'...
remote: Enumerating objects: 278, done.
remote: Counting objects: 100% (278/278), done.
remote: Compressing objects: 100% (249/249), done.
remote: Total 278 (delta 33), reused 93 (delta 16), pack-reused 0
Receiving objects: 100% (278/278), 142.36 KiB | 217.00 KiB/s, done.
Resolving deltas: 100% (33/33), done.
=> Compressing and cleaning up git repository
=> Appending nvm source string to /Users/xuwanxiang/.bash_profile
=> Appending bash_completion source string to /Users/xuwanxiang/.bash_profile
npm ERR! peer dep missing: webpack@^4.0.0, required by [email protected]
=> You currently have modules installed globally with `npm`. These will no
=> longer be linked to the active version of Node when you install a new node
=> with `nvm`; and they may (depending on how you construct your `$PATH`)
=> override the binaries of modules installed with `nvm`:
/usr/local/lib
=> If you wish to uninstall them at a later point (or re-install them under your
=> `nvm` Nodes), you can remove them from the system Node as follows:
$ nvm use system
$ npm uninstall -g a_module
=> Close and reopen your terminal to start using nvm or run the following to use it now:
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
编辑.bash_profile,可以在终端使用nvm命令
$cd ~
$vi .bash_profile
bash_profile添加如下代码
export NVM_DIR="$HOME/.nvm”.”/user/local/opt/nvm/nvm.sh”
然后重新source
$source .bash_profile
安装node的指定版本
nvm install 6.9.5