Server setup
Run container with new data volume
Shell into the container
Set initial password
-
neo4j-admin set-initial-password <password>
(Only works if run before db is started so won't work in docker container)
Shell
-
cypher-shell
User = neo4j, initial password is neo4j
Change password for admin:
Must be done via curl
-
A=$(echo -n "neo4j:neo4j" | base64)
-
curl -H "Content-Type: application/json" \
-
-H "Authorization: Basic ${A}" \
-
-d '{"password":"NEWPASS"}' \
Create user
See https://neo4j.com/docs/operations-manual/3.5/tutorial/role-based-access…
and https://neo4j.com/docs/operations-manual/3.5/authentication-authorizati…
-
CALL dbms.security.createUser('jane', 'abracadabra', false)
false means the password will not need to be changed
Constraints
-
CALL db.constraints
-
-
## CREATE CONSTRAINT ON (n:lab) ASSERT exists(n.id) REQUIRES ENTERPRISE
-
CREATE CONSTRAINT ON (n:lab) ASSERT n.id IS UNIQUE
RJM Article Type
Work Notes