Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

supported various options when docker run #32

Merged
merged 3 commits into from
Feb 22, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 2 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,8 @@ https://hub.docker.com/r/katsubushi/katsubushi/

```
$ docker pull katsubushi/katsubushi
$ docker run -p 11212:11212 katsubushi/katsubushi
```

If you want to specify `worker_id`, set by an environment variable.

```
$ docker run -e "worker_id=123" -p 11212:11212 katsubushi/katsubushi
$ docker run -p 11212:11212 katsubushi/katsubushi -worker-id 1
$ docker run -p 11212:11212 katsubushi/katsubushi -redis redis://your.redis.host:6379/0
```

## Usage
Expand Down
3 changes: 1 addition & 2 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,5 @@ MAINTAINER Fujiwara Shunichiro <fujiwara.shunichiro@gmail.com>
RUN apk --update add unzip curl && rm -rf /var/cache/apk/*
RUN curl -sL https://github.com/kayac/go-katsubushi/releases/download/v1.4.3/katsubushi-1.4.3-linux-amd64.zip > /tmp/katsubushi-1.4.3-linux-amd64.zip && cd /tmp && unzip katsubushi-1.4.3-linux-amd64.zip && install katsubushi /usr/local/bin && rm -f /tmp/katsubushi*

ENV worker_id 1
EXPOSE 11212
CMD ["sh", "-c", "exec /usr/local/bin/katsubushi -worker-id $worker_id"]
ENTRYPOINT ["/usr/local/bin/katsubushi"]