diff --git a/README.md b/README.md index 5755655..cb8f29e 100644 --- a/README.md +++ b/README.md @@ -4,20 +4,17 @@ A Slack integration to notify Docker events. ![slack-docker-0.1.1](https://cloud.githubusercontent.com/assets/321266/4773935/0141e0e8-5ba8-11e4-8b35-601e898c58be.png) -## Run +## How to Run -Set up [an incoming WebHook integration](https://my.slack.com/services/new/incoming-webhook) and get the token. +Set up [an incoming WebHook integration](https://my.slack.com/services/new/incoming-webhook) and get the Webhook URL. -Run a container +Run a container as follows: ```sh -docker run -d -v /var/run/docker.sock:/var/run/docker.sock -e webhook=URL -e channel=infra int128/slack-docker +docker run -d -e webhook=URL -v /var/run/docker.sock:/var/run/docker.sock int128/slack-docker ``` -with following environment variables. - -* `webhook` is the Webhook URL like `https://hooks.slack.com/services/...` -* `channel` is the channel without hash prefix. Default is `general`. +Replace `URL` with your Webhook URL like `https://hooks.slack.com/services/...` ## Contribution diff --git a/app.coffee b/app.coffee index 1ef5689..9c87bfd 100644 --- a/app.coffee +++ b/app.coffee @@ -51,7 +51,7 @@ notify = (name, text, fields) -> slack.send username: "docker#{name}" icon_emoji: ':whale:' - channel: '#' + process.env.channel || 'general' + channel: '' text: text fields: fields