561
社区成员




一、环境准备
还是windows11+wsl2
不过这次使用docker方式
wsl2+docker安装方式参考:https://blog.csdn.net/weixin_48386220/article/details/131920077
二、安装步骤
1.检出secretnote代码
git clone https://github.com/secretflow/secretnote
2.使用docker-compose启动secretnote
cd secretnote/docker/sim
docker-compose up
漫长的等待。。。拉镜像、启动。
拉取完了,启动成功。
三、测试
注意:由于是用docker启动的,容器里的网络和宿主机的网络并不一致,但window的docker会自动在hosts文件增加几个域名,可通过域名:暴漏端口访问。
# Added by Docker Desktop
172.18.3.249 host.docker.internal
172.18.3.249 gateway.docker.internal
# To allow the same kube context to work on the host and the container:
127.0.0.1 kubernetes.docker.internal
# End of section
官方提供的docker-compose文件,对外暴漏了两个端口:8090和8092,通过一下方式访问:
Alice:http://host.docker.internal:8090/
Bob:http://host.docker.internal:8092/
添加节点的时候也使用上述地址。
至此,secret-note可以正常访问,节点状态在线。