您好,登录后才能下订单哦!
这期内容当中小编将会给大家带来有关Mac中怎么创建一个IPFS项目,文章内容丰富且以专业的角度为大家分析和叙述,阅读完这篇文章希望大家可以有所收获。
如果已经有ipfs可以直接复制文件夹
$ cd /Users/shijun/Desktop/openSourceProject/go-ipfs
$ ipfs init
$ /Users/shijun/Desktop/openSourceProject/go-ipfs/ipfs daemon
如果从0开始按一下步骤:
一、下载IPFS
https://dist.ipfs.io/go-ipfs/v0.4.15/go-ipfs_v0.4.15_darwin-amd64.tar.gz
二、安装IPFS
$ sudo ./install.sh
Moved ipfs to /usr/local/bin
$ /Users/shijun/Desktop/openSourceProject/go-ipfs/ipfs init
initializing IPFS node at /Users/shijun/.ipfs
generating 2048-bit RSA keypair...done
peer identity: QmRMqW15KVaE4SWNx827fCGnkFhrJNigLqVVu71W4stqYf
to get started, enter:
ipfs cat /ipfs/QmS4ustL54uo8FzR9455qaxZwuMiUhyvMcX9Ba8nUH4uVv/readme
三、加入节点
$ /Users/shijun/Desktop/openSourceProject/go-ipfs/ipfs daemon
Initializing daemon...
Successfully raised file descriptor limit to 2048.
Swarm listening on /ip4/10.85.110.146/tcp/4001
Swarm listening on /ip4/127.0.0.1/tcp/4001
Swarm listening on /ip6/::1/tcp/4001
Swarm listening on /p2p-circuit/ipfs/QmRMqW15KVaE4SWNx827fCGnkFhrJNigLqVVu71W4stqYf
Swarm announcing /ip4/10.85.110.146/tcp/4001
Swarm announcing /ip4/127.0.0.1/tcp/4001
Swarm announcing /ip6/::1/tcp/4001
API server listening on /ip4/127.0.0.1/tcp/5001
Gateway (readonly) server listening on /ip4/127.0.0.1/tcp/8080
Daemon is ready
四、IPFS ReadMe
$ ipfs cat /ipfs/QmS4ustL54uo8FzR9455qaxZwuMiUhyvMcX9Ba8nUH4uVv/readme
Hello and Welcome to IPFS!
██╗██████╗ ███████╗███████╗
██║██╔══██╗██╔════╝██╔════╝
██║██████╔╝█████╗ ███████╗
██║██╔═══╝ ██╔══╝ ╚════██║
██║██║ ██║ ███████║
╚═╝╚═╝ ╚═╝ ╚══════╝
If you're seeing this, you have successfully installed
IPFS and are now interfacing with the ipfs merkledag!
五、写入文件
$ ipfs add /Users/shijun/Desktop/openSourceProject/go-ipfs/README.md
added QmXBpD37vBm5537pqHwyJRGSaX7hMrkHyp866wqEVU2BE8 README.md
浏览器查看: https://ipfs.io/ipfs/QmXBpD37vBm5537pqHwyJRGSaX7hMrkHyp866wqEVU2BE8
上述就是小编为大家分享的Mac中怎么创建一个IPFS项目了,如果刚好有类似的疑惑,不妨参照上述分析进行理解。如果想知道更多相关知识,欢迎关注亿速云行业资讯频道。
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。