neo4j with docker
2018-07-04 本文已影响83人
lilith买买买
需要把neo4j部署到服务器上使用,看到支持使用docker运行neo4j,这样部署起来就很方便啦
这里先贴上一些资源:
neo4j with docker的文档
git hub 上各版本neo4j的Dockerfile
步骤:
1.我用的是3.4.1社区版的neo4j Dockerfile。创建一个目录(比如docker_neo4j),然后把下图这些文件及目录放到新建的docker_neo4j目录下

2.在docker_neo4j目录下,运行docker build -t neo4j:3.4.1 .
就好啦

3.运行容器,可以参考https://neo4j.com/docs/operations-manual/current/installation/docker/
docker run -d --publish=7474:7474 --publish=7687:7687 \
--volume=$HOME/neo4j/data:/data \
--volume=$HOME/neo4j/logs:/logs \
neo4j:3.4.1
All the volumes in this documentation are stored under $HOME in order to work on OS X where $HOME is automatically mounted into the machine VM. On Linux the volumes can be stored anywhere.