nebula-docker 离线如何部署

  • nebula 版本:2.0.0
  • 部署方式(分布式 / 单机 / Docker / DBaaS):Docker
  • 是否为线上版本:N

已安装docker环境,如何离线部署 nebula-docker-compose?

已有尝试:
1、上传镜像到离线环境
[root@node nebula-docker-compose]# docker images;
REPOSITORY TAG IMAGE ID CREATED SIZE
vesoft/nebula-graph-studio v2 176471e15310 2 months ago 344MB
vesoft/nebula-http-gateway v2 ff3018a288ae 2 months ago 54.7MB
nginx alpine 72ab4137bd85 2 months ago 22.6MB
vesoft/nebula-importer v2 210b83ae40e5 3 months ago 15.2MB

2、创建容器
[root@node nebula-docker-compose]# docker create -it vesoft/nebula-graph-studio:v2
e6e8dc41176a7a1f641fba1ed61de573a6664f6e34f570f81f1b5162b991fda0

[root@node nebula-docker-compose]# docker create -it vesoft/nebula-http-gateway:v2
4823fdf9a98b5547ab76161a8e1d70547286bd5e226a2d218dfab72e82d00a59

[root@node nebula-docker-compose]# docker create -it nginx:alpine
7334d60aa4b4083b32352bc4b08038be973e1271ac72f7786d2e2013105586c3

[root@node nebula-docker-compose]# docker create -it vesoft/nebula-importer:v2
8aef96d74b5b56f8f619f5b7a0af630e3afe65ee2c6e4e125e50385ded0b9535

3、容器查看
[root@node nebula-docker-compose]# docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
8aef96d74b5b vesoft/nebula-importer:v2 “nebula-importer” 36 seconds ago Created goofy_gagarin
7334d60aa4b4 nginx:alpine “/docker-entrypoint.…” 37 seconds ago Created admiring_dewdney
4823fdf9a98b vesoft/nebula-http-gateway:v2 “./nebula-http-gatew…” 37 seconds ago Created brave_bardeen
e6e8dc41176a vesoft/nebula-graph-studio:v2 “docker-entrypoint.s…” 38 seconds ago Created nice_ramanujan

4、启动容器
[root@node nebula-docker-compose]# docker start 8aef96d74b5b
8aef96d74b5b
[root@node nebula-docker-compose]# docker start 7334d60aa4b4
7334d60aa4b4
[root@node nebula-docker-compose]# docker start 4823fdf9a98b
4823fdf9a98b
[root@node nebula-docker-compose]# docker start e6e8dc41176a
e6e8dc41176a

5、查看容器状态
[root@node nebula-docker-compose]# docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
8aef96d74b5b vesoft/nebula-importer:v2 “nebula-importer” About a minute ago Exited (2) 18 seconds ago goofy_gagarin
7334d60aa4b4 nginx:alpine “/docker-entrypoint.…” About a minute ago Up 19 seconds 80/tcp admiring_dewdney
4823fdf9a98b vesoft/nebula-http-gateway:v2 “./nebula-http-gatew…” About a minute ago Up 18 seconds 8080/tcp brave_bardeen
e6e8dc41176a vesoft/nebula-graph-studio:v2 “docker-entrypoint.s…” About a minute ago Up 17 seconds 7001/tcp nice_ramanujan

vesoft/nebula-importer:v2容器退出

6、查看 vesoft/nebula-importer:v2 日志
[root@node nebula-docker-compose]# docker logs 8aef96d74b5b
2021/06/28 09:53:49 — START OF NEBULA IMPORTER —
2021/06/28 09:53:49 open : no such file or directory
2021/06/28 09:53:50 — END OF NEBULA IMPORTER —

你如果使用 docker 命令启动每个容器,需要参考 docker-compose.yaml 中的命令行参数追加到你的 docker 的命令后面,既然你已经讲镜像上传到服务器,可以直接使用 docker-compose 启动了,因为 docker-compose 会检查本地是否有 image,如果有是不会去 docker hub 上拉取镜像的。

如果服务器上没有 docker-compose 文件,可以下载后单独上传,就是一个二进制文件,很好安装。

这里的 importer 退出是因为没有使用服务的模式启动,执行完就会立即退出。还是要看 docker-compose.yaml 中的配置参数。

1 个赞

该话题在最后一个回复创建后30天后自动关闭。不再允许新的回复。

浙ICP备20010487号