Giter Site home page Giter Site logo

botkit-bot's Introduction

Botkit bot

This is the demo for the NodeMN presentation.

To run this project first you need to create a bot user in slack.

https://[YOUR TEAM NAME].slack.com/services/new/bot

Make sure you have docker and docker-compose installed in your computer.

Docker install

Docker Compose install


Clone the repository and run:

$ cd botkit-bot/

$ docker-compose build

$ docker-compose up -d

After these is done you should have a docker service running in the background.

You can verify that it's running by running:

$ docker-compose ps

And should output:

Name          Command     State    Ports
---------------------------------------------
botkitbot_web_1   sleep 9999   Exit 0

Connect to your service:

$ docker-compose run web /bin/bash

You should be able to get a shell with your code included.

You can run an ls to verify.

You are going to need a .env file at the root of the project that looks like this:

NODE_ENV=DEV  // this could be PROD too
SLACK_TOKEN_ID= [your slack bot token id]
TWILIO_ACCOUNT_SID= [Twilio account id]
TWILIO_API_KEY= [Twilio SMS api key]
TWILIO_API_SECRET= [Twilio SMS api secret]
FROM_NUMBER=+15555555555 // numbers registered with Twilio
TO_NUMBER=+16666666666

These are environment variables propagated in your docker image.

Run the code:

$ npm install

$ npm start

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.