You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hugegraph.apache.org by ji...@apache.org on 2026/09/30 18:04:19 UTC
(hugegraph-doc) branch docs/align-toolchain-master updated: docs(hubble): reuse upstream Docker deployment
This is an automated email from the ASF dual-hosted git repository.
imbajin pushed a commit to branch docs/align-toolchain-master
in repository https://gitbox.apache.org/repos/asf/hugegraph-doc.git
The following commit(s) were added to refs/heads/docs/align-toolchain-master by this push:
new 845d0ab4b docs(hubble): reuse upstream Docker deployment
845d0ab4b is described below
commit 845d0ab4b33d942f184095ce9ce879894e985375
Author: imbajin <ji...@apache.org>
AuthorDate: Thu Oct 1 02:04:13 2026 +0800
docs(hubble): reuse upstream Docker deployment
- reference the existing standalone Compose and config
- link distributed setup to the main repository guide
- clarify project isolation, ports and persistent data
- verify startup and bilingual deployment instructions
---
.../docs/quickstart/toolchain/hugegraph-hubble.md | 84 ++++++++------------
.../visualization/hugegraph-hubble-hstore.md | 5 ++
.../docs/quickstart/toolchain/hugegraph-hubble.md | 91 +++++++++-------------
.../visualization/hugegraph-hubble-hstore.md | 6 ++
4 files changed, 78 insertions(+), 108 deletions(-)
diff --git a/content/cn/docs/quickstart/toolchain/hugegraph-hubble.md b/content/cn/docs/quickstart/toolchain/hugegraph-hubble.md
index 9840b7979..e70d7ef02 100644
--- a/content/cn/docs/quickstart/toolchain/hugegraph-hubble.md
+++ b/content/cn/docs/quickstart/toolchain/hugegraph-hubble.md
@@ -14,7 +14,7 @@ Hubble 是 HugeGraph 的 Web 管理与图可视化界面。你可以在同一个
本文以 Toolchain `master`(当前为 `1.8.0`)为准;Docker `latest` 是可变标签,使用时应核对实际版本。
> [!WARNING]
-> **示例只在本机开放端口。** Hubble 提供可修改数据的原生查询入口。生产环境应在可信入口终结 HTTPS,
+> **以下组合用于本地试用。** Hubble 提供可修改数据的原生查询入口。生产环境应在可信入口终结 HTTPS,
> 限制 Hubble 与 Server 的网络访问,并在 Server 开启 [认证与授权](/cn/docs/config/config-authentication/)。
> 保留 Server 的 `audit-*.log` 并限制读取权限;`auth.audit_log_rate` 是速率上限,不是审计开关。
@@ -24,64 +24,43 @@ Hubble 是 HugeGraph 的 Web 管理与图可视化界面。你可以在同一个
## 启动单机组合
-准备 Docker 和 Docker Compose,在一个空目录中保存以下两个文件。Server 保存图数据,Hubble 提供界面;
-它们通过同一个 Docker 网络通信,因此 Hubble 使用 `server:8080`,而不是容器内的 `127.0.0.1`。
+直接使用主仓库 [docker/docker-compose.yml](https://github.com/apache/hugegraph/blob/master/docker/docker-compose.yml),
+无需另外编写一份 Compose。文件已经组合了 RocksDB Server 与 Hubble,并配置网络、健康检查和数据卷;
+部署细节见同目录的 [README](https://github.com/apache/hugegraph/blob/master/docker/README.md)。
-`hugegraph-hubble.properties`:
-
-```properties
-server.host=0.0.0.0
-server.port=8088
-pd.enabled=false
-server.direct_url=http://server:8080
-dashboard.address=
+```bash
+git clone --branch master --single-branch --depth 1 https://github.com/apache/hugegraph.git
+cd hugegraph/docker
```
-`compose.yaml`:
-
-```yaml
-services:
- server:
- image: hugegraph/hugegraph:latest
- ports:
- - "127.0.0.1:18080:8080"
- networks: [graph]
- healthcheck:
- test: ["CMD", "curl", "-fsS", "http://localhost:8080/versions"]
- interval: 5s
- timeout: 5s
- retries: 36
- start_period: 30s
- hubble:
- image: hugegraph/hubble:latest
- depends_on:
- server:
- condition: service_healthy
- ports:
- - "127.0.0.1:18088:8088"
- networks: [graph]
- volumes:
- - ./hugegraph-hubble.properties:/hubble/conf/hugegraph-hubble.properties:ro
-networks:
- graph:
-```
+如果已有主仓库,直接进入它的 `docker/` 目录。Compose 挂载该目录下的
+[`conf/hubble/standalone.properties`](https://github.com/apache/hugegraph/blob/master/docker/conf/hubble/standalone.properties),
+其中 `pd.enabled=false`、`server.direct_url=http://server:8080`:两个服务在同一 Docker 网络中通信,不需要填写每图 Server 地址。
+不要只下载 YAML 后从其他目录启动,否则相对配置文件路径可能不存在。
+
+Hubble 默认只在宿主机回环地址开放 `8088`;Server 默认发布 `8080`。仅本机试用时,将 Compose 中 Server 的
+`ports` 改为 `127.0.0.1:8080:8080`,避免对其他机器开放匿名接口。
+
+为本次试用选一个未被使用的项目名,后续命令在同一终端沿用这些变量;另开终端时恢复本次项目名。
```bash
+export HUGEGRAPH_VERSION=latest
+export HUBBLE_IMAGE=hugegraph/hubble:latest
export HUBBLE_DEMO_PROJECT="hubble-demo-$(date +%Y%m%d-%H%M%S)"
docker compose ls
-docker compose -p "$HUBBLE_DEMO_PROJECT" pull
-docker compose -p "$HUBBLE_DEMO_PROJECT" up -d
-docker compose -p "$HUBBLE_DEMO_PROJECT" ps
-curl -fsS http://127.0.0.1:18080/versions
+docker compose -p "$HUBBLE_DEMO_PROJECT" -f docker-compose.yml pull
+docker compose -p "$HUBBLE_DEMO_PROJECT" -f docker-compose.yml up -d --wait
+docker compose -p "$HUBBLE_DEMO_PROJECT" -f docker-compose.yml ps
+curl -fsS http://127.0.0.1:8080/versions
```
-项目名跨目录共享:确认生成的名称未被其他项目使用,后续命令在同一终端沿用该变量;另开终端时恢复本次项目名。
-
-Server 健康后,打开 <http://127.0.0.1:18088>。此示例没有配置 Server 认证,Hubble 直接进入首页;
-Server 开启认证时,使用 Server 账号登录,Hubble 没有独立账号库。个人中心与账号管理只在相应认证和权限条件下显示。
+服务健康后,打开 <http://127.0.0.1:8088>。全新目录未配置 `HUGEGRAPH_ADMIN_PASSWORD` 时,Server 允许匿名访问,
+Hubble 直接进入首页。需要认证时,按 Docker README 配置 `.env` 中的管理员密码与 JWT 密钥,使用 Server 账号登录;
+Hubble 没有独立账号库。个人中心与账号管理只在相应认证和权限条件下显示,不要覆盖已有 `.env`。
`latest` 便于体验当前功能,正式部署应固定镜像版本或 digest。镜像是便捷分发物,正式发布包见 [下载页](/cn/docs/download/download/)。
-Server 镜像会自动创建匿名卷,此示例仅用于试用;持久化与生产配置见 [Server 部署指南](/cn/docs/quickstart/hugegraph/hugegraph-server/)。
+Compose 的 `server-data` 和 `hubble-data` 分别保存图数据与 Hubble 元数据;更多持久化与生产配置见
+[Server 部署指南](/cn/docs/quickstart/hugegraph/hugegraph-server/)。
## 先用一张示例图认识工作台
@@ -183,7 +162,7 @@ Hubble 导入适合小规模体验,大批量正式导入请使用 [HugeGraph L
| 现象 | 先检查 |
|---|---|
-| Hubble 页面打不开 | `docker compose -p "$HUBBLE_DEMO_PROJECT" ps` 与 `docker compose -p "$HUBBLE_DEMO_PROJECT" logs hubble`;确认配置中的 `server.host=0.0.0.0` |
+| Hubble 页面打不开 | 检查容器状态及 `docker compose -p "$HUBBLE_DEMO_PROJECT" -f docker-compose.yml logs hubble` |
| 页面打开但无法访问图 | Server 是否健康,`server.direct_url` 是否能从 Hubble 容器访问,两个容器是否在同一网络 |
| 出现登录页或没有写操作入口 | Server 的认证模式和当前账号权限;Hubble 不单独开启认证 |
| 查询没有预期数据 | 顶部当前图、示例是否加载成功、标签和属性是否一致;区分画布展示与 Server 数据 |
@@ -195,13 +174,14 @@ FILE 上传默认允许 `csv,txt`,单文件 1 GB、总量 10 GB;需要覆盖
## 停止试用环境或从源码构建
-不再需要示例时,在保存 Compose 文件的目录执行:
+不再需要示例时,在主仓库的 `docker/` 目录执行:
```bash
-docker compose -p "${HUBBLE_DEMO_PROJECT:?}" down --volumes
+docker compose -p "${HUBBLE_DEMO_PROJECT:?}" -f docker-compose.yml down --volumes
```
-这会删除该项目的容器、网络和匿名卷,示例数据也会丢失。已有持久化配置需按自己的数据保留要求处理。
+这会删除该项目的容器、网络、命名卷与匿名卷,示例图和 Hubble 导入任务也会丢失。
+若想保留数据,下线时省略 `--volumes`,以后用同一项目名启动。
需要与 master 精确一致的产物时,使用 JDK 11 和 Maven 从 Toolchain 构建。
Maven 插件会安装所需的 Node/Yarn,无需预先安装;以下命令不执行测试:
diff --git a/content/cn/docs/quickstart/toolchain/visualization/hugegraph-hubble-hstore.md b/content/cn/docs/quickstart/toolchain/visualization/hugegraph-hubble-hstore.md
index c6baa947a..721a03aa7 100644
--- a/content/cn/docs/quickstart/toolchain/visualization/hugegraph-hubble-hstore.md
+++ b/content/cn/docs/quickstart/toolchain/visualization/hugegraph-hubble-hstore.md
@@ -10,6 +10,11 @@ search_keywords: [HugeGraph Hubble, HStore, PD, GraphSpace, 集群管理]
[Hubble 基础与单机指南](/cn/docs/quickstart/toolchain/hugegraph-hubble/)。
内容以 Toolchain `master` 为准;本篇配置与功能经源码核查,未进行分布式环境运行验证。
+主仓库的 [docker/docker-compose-hstore.yml](https://github.com/apache/hugegraph/blob/master/docker/docker-compose-hstore.yml)
+已提供 PD、Store、Server 与 Hubble 的组合。按同目录 [Docker README](https://github.com/apache/hugegraph/blob/master/docker/README.md)
+准备 `.env` 和生成的 Hubble 本地配置,再从 `docker/` 目录启动;不要另维护一份部署 YAML。
+下文配置用于解释连接差异,不能替代 README 中 PD 凭据及服务就绪的要求。
+
## 连接分布式集群
Hubble 仍通过 **Server 的图 API** 管理数据。区别在于,分布式模式通过 PD 发现 Server,
diff --git a/content/en/docs/quickstart/toolchain/hugegraph-hubble.md b/content/en/docs/quickstart/toolchain/hugegraph-hubble.md
index 349f50749..ba3a87378 100644
--- a/content/en/docs/quickstart/toolchain/hugegraph-hubble.md
+++ b/content/en/docs/quickstart/toolchain/hugegraph-hubble.md
@@ -14,7 +14,7 @@ For HStore, read the shared operations here first, then follow the [distributed
This guide follows Toolchain `master` (currently `1.8.0`); Docker `latest` is mutable, so check the actual running versions.
> [!WARNING]
-> **The example exposes ports on your machine only.** Hubble accepts native queries that can modify data. In production,
+> **The deployment below is for a local trial.** Hubble accepts native queries that can modify data. In production,
> terminate HTTPS at a trusted entry point, restrict network access to Hubble and Server, and enable
> [Server authentication and authorization](/docs/config/config-authentication/).
> Retain Server's `audit-*.log` with restricted access; `auth.audit_log_rate` is a rate limit, not an audit switch.
@@ -25,68 +25,47 @@ The sample and import below were exercised; availability of newer master feature
## Start the standalone pair
-Install Docker and Docker Compose, then save the two files below in an empty directory. Server stores graph data and Hubble provides the UI.
-They communicate over one Docker network, so Hubble uses `server:8080`, not `127.0.0.1` inside its container.
+Use the main repository's [docker/docker-compose.yml](https://github.com/apache/hugegraph/blob/master/docker/docker-compose.yml)
+instead of writing another Compose file. It already combines RocksDB Server and Hubble, with networking, health checks, and data volumes.
+See the adjacent [README](https://github.com/apache/hugegraph/blob/master/docker/README.md) for deployment details.
-`hugegraph-hubble.properties`:
-
-```properties
-server.host=0.0.0.0
-server.port=8088
-pd.enabled=false
-server.direct_url=http://server:8080
-dashboard.address=
+```bash
+git clone --branch master --single-branch --depth 1 https://github.com/apache/hugegraph.git
+cd hugegraph/docker
```
-`compose.yaml`:
-
-```yaml
-services:
- server:
- image: hugegraph/hugegraph:latest
- ports:
- - "127.0.0.1:18080:8080"
- networks: [graph]
- healthcheck:
- test: ["CMD", "curl", "-fsS", "http://localhost:8080/versions"]
- interval: 5s
- timeout: 5s
- retries: 36
- start_period: 30s
- hubble:
- image: hugegraph/hubble:latest
- depends_on:
- server:
- condition: service_healthy
- ports:
- - "127.0.0.1:18088:8088"
- networks: [graph]
- volumes:
- - ./hugegraph-hubble.properties:/hubble/conf/hugegraph-hubble.properties:ro
-networks:
- graph:
-```
+If you already have the main repository, enter its `docker/` directory. Compose mounts
+[`conf/hubble/standalone.properties`](https://github.com/apache/hugegraph/blob/master/docker/conf/hubble/standalone.properties)
+from that directory. It sets `pd.enabled=false` and `server.direct_url=http://server:8080`;
+both services communicate over one Docker network, without a Server address configured per graph.
+Do not download only the YAML and start it from another directory: relative configuration files may be missing.
+
+Hubble defaults to host loopback port `8088`; Server publishes `8080`. For a trial on your machine only, change Server's
+`ports` entry to `127.0.0.1:8080:8080` to avoid exposing the anonymous API to other machines.
+
+Choose an unused project name for this trial and keep these variables in the same terminal.
+Restore this project name if you use another terminal.
```bash
+export HUGEGRAPH_VERSION=latest
+export HUBBLE_IMAGE=hugegraph/hubble:latest
export HUBBLE_DEMO_PROJECT="hubble-demo-$(date +%Y%m%d-%H%M%S)"
docker compose ls
-docker compose -p "$HUBBLE_DEMO_PROJECT" pull
-docker compose -p "$HUBBLE_DEMO_PROJECT" up -d
-docker compose -p "$HUBBLE_DEMO_PROJECT" ps
-curl -fsS http://127.0.0.1:18080/versions
+docker compose -p "$HUBBLE_DEMO_PROJECT" -f docker-compose.yml pull
+docker compose -p "$HUBBLE_DEMO_PROJECT" -f docker-compose.yml up -d --wait
+docker compose -p "$HUBBLE_DEMO_PROJECT" -f docker-compose.yml ps
+curl -fsS http://127.0.0.1:8080/versions
```
-Project names are shared across directories: check that the generated name is unused. Keep the same variable in this terminal;
-restore this project name if you use another terminal.
-
-Once Server is healthy, open <http://127.0.0.1:18088>. This example does not configure Server authentication, so Hubble opens the home page directly.
-If Server authentication is enabled, sign in with a Server account; Hubble has no separate account database.
-Personal and account-management pages appear only when the authentication mode and your permissions support them.
+Once services are healthy, open <http://127.0.0.1:8088>. In a fresh directory without `HUGEGRAPH_ADMIN_PASSWORD`,
+Server allows anonymous access and Hubble opens the home page directly. For authentication, follow the Docker README to configure
+an administrator password and JWT secret in `.env`, then sign in with a Server account. Hubble has no separate account database.
+Personal and account-management pages depend on the authentication mode and your permissions. Do not overwrite an existing `.env`.
Use `latest` to try current features, and pin a published image version or digest for production.
Images are convenience distributions; official release archives are on the [download page](/docs/download/download/).
-The Server image creates an anonymous volume; this example is for testing only. For persistence and production settings, see
-the [Server deployment guide](/docs/quickstart/hugegraph/hugegraph-server/).
+Compose's `server-data` and `hubble-data` retain graph data and Hubble metadata respectively. For further persistence and production settings,
+see the [Server deployment guide](/docs/quickstart/hugegraph/hugegraph-server/).
## Learn the workspace with a sample graph
@@ -198,7 +177,7 @@ for production bulk ingestion.
| Symptom | Check first |
|---|---|
-| The Hubble page does not open | `docker compose -p "$HUBBLE_DEMO_PROJECT" ps` and `docker compose -p "$HUBBLE_DEMO_PROJECT" logs hubble`; verify `server.host=0.0.0.0` |
+| The Hubble page does not open | Check container status and `docker compose -p "$HUBBLE_DEMO_PROJECT" -f docker-compose.yml logs hubble` |
| The page opens but graphs are unavailable | Server health, a `server.direct_url` reachable from Hubble, and a shared network |
| Login appears or write actions are missing | Server authentication and account permissions; Hubble has no independent authentication switch |
| Expected data is missing | Current graph, sample load result, matching labels/properties; distinguish canvas display from stored data |
@@ -210,14 +189,14 @@ FILE uploads allow `csv,txt` by default, with 1 GB per file and 10 GB total. Ove
## Stop the trial or build from source
-When finished, run this in the directory containing your Compose file:
+When finished, run this in the main repository's `docker/` directory:
```bash
-docker compose -p "${HUBBLE_DEMO_PROJECT:?}" down --volumes
+docker compose -p "${HUBBLE_DEMO_PROJECT:?}" -f docker-compose.yml down --volumes
```
-This removes the project's containers, network, and anonymous volume, losing the example data.
-Handle any persistent storage separately according to your data-retention requirements.
+This removes the project's containers, network, named volumes, and anonymous volume, losing the sample data and Hubble import tasks.
+To retain data, omit `--volumes` when taking the deployment down and reuse the same project name when starting it again.
To obtain an exact master build, use JDK 11 and Maven. The Maven plugin installs the required Node/Yarn;
you do not need to install them separately. These commands skip tests:
diff --git a/content/en/docs/quickstart/toolchain/visualization/hugegraph-hubble-hstore.md b/content/en/docs/quickstart/toolchain/visualization/hugegraph-hubble-hstore.md
index cce2c0f04..5612012c8 100644
--- a/content/en/docs/quickstart/toolchain/visualization/hugegraph-hubble-hstore.md
+++ b/content/en/docs/quickstart/toolchain/visualization/hugegraph-hubble-hstore.md
@@ -10,6 +10,12 @@ This guide covers the differences between HStore + PD and standalone RocksDB.
For modeling, importing data, and querying, see the [Hubble standalone guide](/docs/quickstart/toolchain/hugegraph-hubble/).
The configuration and features below were checked against Toolchain `master`; they have not been verified in a running distributed environment.
+The main repository's [docker/docker-compose-hstore.yml](https://github.com/apache/hugegraph/blob/master/docker/docker-compose-hstore.yml)
+already combines PD, Store, Server, and Hubble. Follow the adjacent
+[Docker README](https://github.com/apache/hugegraph/blob/master/docker/README.md) to prepare `.env` and generated Hubble local configuration,
+then start it from `docker/`; do not maintain another deployment YAML.
+The settings below explain connection differences and do not replace the README's PD credential and service-readiness requirements.
+
## Connect to a distributed cluster
Hubble still manages graph data through the **Server graph API**. In distributed mode, it discovers Servers through PD