Individual bots can be set up manually without nodeservices also. The process is described below:
- Clone our OnBot repository from github (git clone -b master https://github.com/CognizantOneDevOps/OnBot.git)
- Copy the desired bot scripts from the scripts folder of the cloned repo
- Run this command: npm install -g yo generator-hubot
- Create a parent folder myhubot
- Run the following commands:
cd myhubot
yo hubot
- Copy the scripts from the cloned repository (first step) into myhubot/scripts folder
- Copy the workflow.json and package.json file into the myhubot directory
- Run: npm install
- Now set the required environment variables and start the bot: ./bin/hubot -a <adapter>
MONITOR_INTERVAL (Time Interval for monitoring bot)
MONITOR_RETENSION (mapped to 1 (stores a jsonobj in elasticsearch which has all hubot metrics of a current second))
MONGO_DB_URL (mongodb database name for approval process of bot actions)
MONGO_COLL (mongodb collection name for approval process of bot actions)
MONGO_COUNTER (mongodb collection name for storing the number of next ticket to be generated)
MONGO_TICKETIDGEN (stores the Id of the collection referred by MONGO_COUNTER)
APPROVAL_APP_URL (middleware application endpoint which will handle approval flow in mattermost)
MONGO_DB_NAME (The database name which has MONGO_COLL and MONGO_COUNTER in it)
0 Comments