slack-bot
🤖 Slack api bot by golang
Golang
$ brew install go
$ go version
go version go1.11.5 darwin/amd64
Modules (vgo)
$ env | grep GO111MODULE
GO111MODULE=on
In my case, I want to manage all the source code in GOPATH, so this is necessary.
Dependencies
Run
$ SLACK_TOKEN=xxxxx PORT=3000 go run main.go
Docker
$ docker build -t jnst/slack-bot .
$ docker run -it --rm -e SLACK_TOKEN=xxxxx -e PORT=3000 jnst/slack-bot
Deploy on Heroku
$ heroku login
$ heroku create
$ heroku git:remote -a xxx-xxx-00001
$ heroku config:set SLACK_TOKEN=xxxxx
$ heroku config:set PORT=3000
$ heroku container:login
$ heroku container:push web
$ heroku container:release web