Skip to content

Commit 758f57b

Browse files
authored
Update to latest hubot and slack adapter (#192)
2 parents 533fe27 + ce916bb commit 758f57b

File tree

12 files changed

+2058
-4708
lines changed

12 files changed

+2058
-4708
lines changed

.circleci/config.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,8 @@ jobs:
103103
-e ST2_HOSTNAME=${ST2_HOSTNAME} \
104104
-e ST2_USERNAME=${ST2_USER} \
105105
-e ST2_PASSWORD=${ST2_PASSWORD} \
106-
-e SLACK_TOKEN=${SLACK_TOKEN} \
106+
-e SLACK_TOKEN=${SLACK_BOT_TOKEN} \
107+
-e SLACK_APP_TOKEN=${SLACK_APP_TOKEN} \
107108
${DISTRO}-test test
108109
- run:
109110
name: Collect logs

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@ node_modules
33
.hubot_history
44
.idea
55
debian/*.log
6+
.vscode

README.md

Lines changed: 5 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# StackStorm's st2chatops
22

33
This repository delivers [StackStorm Chatops](https://docs.stackstorm.com/chatops) in a form of packages and docker image. The package includes [hubot](https://hubot.github.com/), [hubot-stackstorm](https://github.com/StackStorm/hubot-stackstorm)
4-
and pre-installed adapters for many Chat services.
4+
and pre-installed adapters for Slack.
55

66
## Package
77

@@ -36,19 +36,11 @@ Where ${DISTRO} refers to flavor name. See [docker-compose.yml](docker-compose.y
3636

3737
export $ST2_HOSTNAME={MY_STACKSTORM_HOST_NAME}
3838

39-
* Use [`st2chatops.env`](st2chatops.env) to store the settings. The example uses Slack; set appropriate environment variables for other Chat Services:
40-
[Slack](https://github.com/slackhq/hubot-slack),
41-
[Microsoft Teams](https://github.com/Microsoft/BotFramework-Hubot),
42-
[Cisco Spark](https://github.com/tonybaloney/hubot-spark),
43-
[Flowdock](https://github.com/flowdock/hubot-flowdock),
44-
[IRC](https://github.com/nandub/hubot-irc),
45-
[XMPP](https://github.com/markstory/hubot-xmpp),
46-
[RocketChat](https://www.github.com/RocketChat/hubot-rocketchat),
47-
[Mattermost](https://github.com/loafoe/hubot-matteruser).
48-
39+
* Use [`st2chatops.env`](st2chatops.env) to store the settings.
40+
[Slack](https://github.com/hubot-friends/hubot-slack),
4941

5042
* Use [scripts/st2chatops-docker-run.sh](scripts/st2chatops-docker-run.sh) to start the docker container instance.
51-
The script is set for Slack; for other Chats, **edit it** to pass the environment variables as required for your Chat service adapter.
43+
The script is set for Slack
5244
Run the script, and ensure that hubot-stackstorm is running and there are no errors:
5345

5446
./st2chatops-docker-run.sh
@@ -62,7 +54,7 @@ Run the script, and ensure that hubot-stackstorm is running and there are no err
6254

6355
### Node Version
6456

65-
Grab your favorite Node.JS version (>=10.0, <=14.x), and pick your tag. Update `Dockerfile` as needed.
57+
Grab your favorite Node.JS version (>=20.0), and pick your tag. Update `Dockerfile` as needed.
6658

6759
### Pre-Requsites
6860

@@ -86,11 +78,6 @@ Grab your favorite Node.JS version (>=10.0, <=14.x), and pick your tag. Update `
8678

8779
* Step 4: Profit
8880

89-
### Updating
90-
91-
* `hubot-slack` is not compatible with coffeescript 2 ([issue](https://github.com/slackapi/hubot-slack/issues/526), [PR](https://github.com/slackapi/hubot-slack/pull/528)) yet, so keep the `coffee-script` dependency pinned to `1.12.7`
92-
* `coffee-register` is required for dynamic `require`, but it cannot be updated past `1.0.0` because more recent versions (eg: `2.0.0`+) require coffeescript version `2.0.0`+
93-
9481
### Copyright, License, and Contributors Agreement
9582

9683
Copyright 2015-2019 Extreme Networks, Inc.

bin/hubot

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,4 @@ if [ ! -n "$HUBOT_ALIAS" ]; then
4343
fi
4444

4545
# Keep st2chatops hack (ignored by hubot) for process discovery
46-
exec $HERE/node_modules/.bin/hubot "$@" st2chatops
46+
exec $HERE/node_modules/.bin/hubot "$@" -a @hubot-friends/hubot-slack st2chatops

docker-compose.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# Packaging environments
2+
23
focal:
34
build: ./packagingenv/focal
45
extends:

0 commit comments

Comments
 (0)