StackStorm / st2

StackStorm (aka "IFTTT for Ops") is event-driven automation for auto-remediation, incident responses, troubleshooting, deployments, and more for DevOps and SREs. Includes rules engine, workflow, 160 integration packs with 6000+ actions (see https://exchange.stackstorm.org) and ChatOps. Installer at https://docs.stackstorm.com/install/index.html
https://stackstorm.com/
Apache License 2.0
6.09k stars 746 forks source link

st2chatops Rocket.Chat hubot will not start #5308

Open MrDiba opened 3 years ago

MrDiba commented 3 years ago

SUMMARY

This is actual a cross-post for a st2chatops issue https://github.com/StackStorm/st2chatops/issues/167

st2chatops will not start using the Rocket.Chat adapter in a VM and configured in Docker.

STACKSTORM VERSION

st2 --version: st2 3.5.0, on Python 3.8.10 and the stackstorm/st2chatops:3.5 docker container

OS, environment, install method

OS: 20.04.2 LTS (Focal Fossa), clean installation ST2 installation using the Quick install script

Docker version: Docker version 20.10.7, build f0df350

Steps to reproduce the problem

  1. Install ST2 using the quick install option from https://docs.stackstorm.com/install/index.html.
  2. Edit /opt/stackstorm/chatops/st2chatops.env with the correct information;
    HUBOT_ADAPTER=rocketchat
    ROCKETCHAT_URL=<rocketchat url>
    ROCKETCHAT_USER=<bot name>
    ROCKETCHAT_PASSWORD=<bot password>
    ROCKETCHAT_ROOM=<default room>
  3. systemctl restart st2chatops
  4. tail -f /var/log/syslog

Expected Results

I expect that chatops just starts and works.

Actual Results

chatops keeps restarting giving the following error:

Jul 22 09:07:28 stackstorm systemd[1]: Started StackStorm service st2chatops.
Jul 22 09:07:28 stackstorm hubot[44063]: Thu, 22 Jul 2021 09:07:28 GMT body-parser deprecated undefined extended: provide extended option at node_modules/hubot/src/robot.js:445:21
Jul 22 09:07:28 stackstorm hubot[44063]: [Thu Jul 22 2021 09:07:28 GMT+0000 (Coordinated Universal Time)] DEBUG Loading adapter rocketchat
Jul 22 09:07:28 stackstorm hubot[44063]: [Thu Jul 22 2021 09:07:28 GMT+0000 (Coordinated Universal Time)] ERROR Cannot load adapter rocketchat - Error: Cannot find module 'ddp.js'
Jul 22 09:07:28 stackstorm hubot[44063]: Require stack:
Jul 22 09:07:28 stackstorm hubot[44063]: - /opt/stackstorm/chatops/node_modules/@rocket.chat/sdk/node_modules/asteroid/dist/asteroid.node.js
Jul 22 09:07:28 stackstorm hubot[44063]: - /opt/stackstorm/chatops/node_modules/@rocket.chat/sdk/dist/lib/driver.js
Jul 22 09:07:28 stackstorm hubot[44063]: - /opt/stackstorm/chatops/node_modules/@rocket.chat/sdk/dist/index.js
Jul 22 09:07:28 stackstorm hubot[44063]: - /opt/stackstorm/chatops/node_modules/hubot-rocketchat/index.js
Jul 22 09:07:28 stackstorm hubot[44063]: - /opt/stackstorm/chatops/node_modules/hubot/src/robot.js
Jul 22 09:07:28 stackstorm hubot[44063]: - /opt/stackstorm/chatops/node_modules/hubot/es2015.js
Jul 22 09:07:28 stackstorm hubot[44063]: - /opt/stackstorm/chatops/node_modules/hubot/index.js
Jul 22 09:07:28 stackstorm hubot[44063]: - /opt/stackstorm/chatops/node_modules/hubot/bin/hubot.js
Jul 22 09:07:28 stackstorm hubot[44063]: - /opt/stackstorm/chatops/node_modules/hubot/bin/hubot
Jul 22 09:07:28 stackstorm systemd[1]: st2chatops.service: Main process exited, code=exited, status=1/FAILURE
Jul 22 09:07:28 stackstorm systemd[1]: st2chatops.service: Failed with result 'exit-code'.
Jul 22 09:07:33 stackstorm systemd[1]: st2chatops.service: Scheduled restart job, restart counter is at 1037.
Jul 22 09:07:33 stackstorm systemd[1]: Stopped StackStorm service st2chatops.
nzlosh commented 3 years ago

As a workaround to your problem, you can try using err-stackstorm. https://err-stackstorm.readthedocs.io/en/latest/

stale[bot] commented 2 years ago

Thanks for contributing to this issue. As it has been 90 days since the last activity, we are automatically marking is as stale. If this issue is not relevant or applicable anymore (problem has been fixed in a new version or similar), please close the issue or let us know so we can close it. On the contrary, if the issue is still relevant, there is nothing you need to do, but if you have any additional details or context which would help us when working on this issue, please include it as a comment to this issue.