Skip to content

Commit

Permalink
add docker policy and run server in daemon
Browse files Browse the repository at this point in the history
  • Loading branch information
aroundabout committed Dec 15, 2023
1 parent 4975446 commit 1e8d14e
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 5 deletions.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,12 @@ Billions of vertices and edges can be easily stored into and queried from HugeGr

### 1. Docker Way

> Note: The docker image of hugegraph is a convenience release, not official distribution artifacts from ASF. You can find more details from [ASF Release Distribution Policy](https://infra.apache.org/release-distribution.html#dockerhub).
> Note: Recommand to use `release tag`(like `1.0.0`) for the stable version. Use `latest` tag to experience the newest functions in development.
We can use `docker run -itd --name=graph -p 8080:8080 hugegraph/hugegraph` to quickly start an inner
HugeGraph server with `RocksDB` in backgrounds. (Use `release tag`(like `1.0.0`) for the stable version)
HugeGraph server with `RocksDB` in backgrounds.

Optional:

Expand Down
1 change: 1 addition & 0 deletions hugegraph-server/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ RUN set -x \
procps \
curl \
lsof \
vim \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

Expand Down
8 changes: 6 additions & 2 deletions hugegraph-server/hugegraph-dist/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Deploy Hugegraph server with docker

> Note: The docker image of hugegraph is a convenience release, not official distribution artifacts from ASF. You can find more details from [ASF Release Distribution Policy](https://infra.apache.org/release-distribution.html#dockerhub).
> Note: Recommand to use `release tag`(like `1.0.0`) for the stable version. Use `latest` tag to experience the newest functions in development.
## 1. Deploy

We can use docker to quickly start an inner HugeGraph server with RocksDB in background.
Expand All @@ -18,7 +22,7 @@ We can use docker to quickly start an inner HugeGraph server with RocksDB in bac
graph:
image: hugegraph/hugegraph
ports:
- 18080:8080
- 8080:8080
```
## 2. Create Sample Graph on Server Startup
Expand Down Expand Up @@ -46,7 +50,7 @@ If you want to customize the pre-loaded data, please mount the the groovy script
volumes:
- /path/to/yourscript:/hugegraph/scripts/example.groovy
ports:
- 18080:8080
- 8080:8080
```

3. Using start-hugegraph.sh
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@

./bin/init-store.sh

./bin/start-hugegraph.sh -d false -j "$JAVA_OPTS" -g zgc
./bin/start-hugegraph.sh -j "$JAVA_OPTS" -g zgc
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
import org.apache.hugegraph.HugeFactory
import org.apache.hugegraph.dist.RegisterUtil

// register all the backend to avoid changes if docker needs to support othre backend
// register all the backend to avoid changes if needs to support othre backend
RegisterUtil.registerPlugins()
RegisterUtil.registerRocksDB()
RegisterUtil.registerCassandra()
Expand Down

0 comments on commit 1e8d14e

Please sign in to comment.