A getting started thing

docker run -it -p 8080:8888 -p 9080:8889 -v ~/dgraph:/dgraph --name dgraph dgraph/dgraph dgraphzero -w zw
Setting up listener at: localhost:8888
Setting up listener at: localhost:8889
2017/10/10 11:41:14 node.go:234: Found hardstate: {Term:2 Vote:1 Commit:4 XXX_unrecognized:[]}
2017/10/10 11:41:14 node.go:246: Group 0 found 4 entries
2017/10/10 11:41:14 raft.go:292: Restarting node for dgraphzero
2017/10/10 11:41:14 raft.go:567: INFO: 1 became follower at term 2
2017/10/10 11:41:14 raft.go:315: INFO: newRaft 1 [peers: [], term: 2, commit: 4, applied: 0, lastindex: 4, lastterm: 2]
Running Dgraph zero...
2017/10/10 11:41:17 raft.go:749: INFO: 1 is starting a new election at term 2
2017/10/10 11:41:17 raft.go:580: INFO: 1 became candidate at term 3
2017/10/10 11:41:17 raft.go:664: INFO: 1 received MsgVoteResp from 1 at term 3
2017/10/10 11:41:17 raft.go:621: INFO: 1 became leader at term 3
2017/10/10 11:41:17 node.go:301: INFO: raft.node: 1 elected leader 1 at term 3
^CShutting down...
2017/10/10 11:41:57 gRpc server stopped : accept tcp 127.0.0.1:8888: use of closed network connection
2017/10/10 11:41:57 Stopped taking more http(s) requests. Err: accept tcp 127.0.0.1:8889: use of closed network connection
2017/10/10 11:41:57 All http(s) requests finished.
All done.
darko@wrk ~ $ docker start dgraph 
dgraph
darko@wrk ~ $ docker ps
CONTAINER ID        IMAGE               COMMAND              CREATED             STATUS              PORTS                                                                NAMES
f4b75c05ff4a        dgraph/dgraph       "dgraphzero -w zw"   49 seconds ago      Up 2 seconds        8080/tcp, 9090/tcp, 0.0.0.0:8080->8888/tcp, 0.0.0.0:9080->8889/tcp   dgraph
$ go run main.go
Creating a forum and associated threads and posts.

2017/10/10 13:42:23 rpc error: code = Unavailable desc = transport is closing
exit status 1