Skip to content

Commit b0e1ffd

Browse files
committed
Implement docker-compose support. It is easier to use than the old Makefile.
1 parent 4f8a1c2 commit b0e1ffd

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ Install `docker` on your system. 1.0 or higher is recommended. Instructions can
2020

2121
# Usage
2222

23+
If you want to use `docker-compose (fig)` please read next section.
24+
2325
Download the latest build from docker hub with `docker pull grokzen/redis-cluster`
2426

2527
To build the image run either `make build` or `make rebuild`. It will be built to the image name `grokzen/redis-cluster`.
@@ -30,6 +32,16 @@ Test to connect to the cluster with `redis-cli -p 7000`. If you do not want to i
3032

3133

3234

35+
# Docker compose (fig)
36+
37+
This image contains a `compose.yml` file that can be used with `docker-compose (fig)` to run the image. Docker compose is simpler to use then the old `Makefile`.
38+
39+
Build the image with `docker-compose -f compose.yml build`.
40+
41+
Start the image after building with `docker-compose -f compose.yml up`. Add `-d` to run the server in background/detatched mode.
42+
43+
44+
3345
# Known Issues
3446

3547
If you get a error when rebuilding the image that docker can't do dns lookup on `archive.ubuntu.com` then you need to modify docker to use google IPv4 DNS lookups. Read the following link http://dannytsang.co.uk/docker-on-digitalocean-cannot-resolve-hostnames/ and uncomment the line in `/etc/default/docker` and restart your docker daemon and it should be fixed.

compose.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
server:
2+
build: .
3+
hostname: server
4+
expose:
5+
- "7000:7000"
6+
- "7001:7001"
7+
- "7002:7002"
8+
- "7003:7003"
9+
- "7004:7004"
10+
- "7005:7005"
11+
- "7006:7006"
12+
- "7007:7007"

0 commit comments

Comments
 (0)