Git Product home page Git Product logo

terraform-aws-slack-pivotal-tracker-bot's Introduction

DEPRECATION NOTICE

This project is no longer being maintained.

slack-pivotal-tracker-bot AWS module

This is the Terraform module for deploying slack-pivotal-tracker-bot to AWS Lambda

Please refer to the application code repo for more information on usage.

Inputs

Name Description Default Required
pivotal_token API Token for accessing pivotal projects - yes
region AWS region us-west-2 no
slack_token API token for posting Slack messages - yes
stage_name Stage name of API deployment, e.g. production production no

Outputs

Name Description
slack_webhook_url

Installation

Installation is accomplished in four parts:

  1. Generate Pivotal Tracker API token
  2. Create a Slack slash command
  3. Deploy Terraform module with API tokens
  4. Update slash command with output URL

Generate Pivotal Tracker API token

slack-pivotal-tracker-bot will use this API token to authenticate with Pivotal Tracker, allowing it to edit whatever projects that user has access to. We recommend you create a user specifically for this slack bot so you can better control that user's permissions.

  • While logged in, visit your Pivotal Tracker profile and scroll down to API Token
  • Click Create New Token, and save it for step 3

Create a Slack slash command

Next, you will create a slash command in Slack, which allows users to enter commands that are sent to a webhook URL:

  • Navigate to your server's custom integrations page: https://YOUR-SERVER.slack.com/apps/manage/custom-integrations
  • Go to your slash commands application and click on "Add Configuration"
  • Add your preferred command (e.g. /pivotal), and click add
  • Scroll down to integration settings and enter these settings:
    • Command: Should already be filled
    • URL(s): Leave blank for now
    • Method: POST
    • Token: This comes pre-filled, but save it for step 3
    • Customize Name: Name it whatever you'd like!
    • Customize Icon: Up to you
    • Autocomplete help text: Enter some text that you think will help the user
    • Translate User IDs: Leave checked
  • Save integration

Deploy Terraform module with API tokens

With your API tokens in hand, deploy the module as shown below:

module "pivotal_tracker_bot" {
  source  = "trussworks/pivotal-tracker-bot/slack"
  version = "0.0.1"

  pivotal_token = "${var.pivotal_token}"
  slack_token   = "${var.slack_token}"
  region        = "${var.region}"
  stage_name    = "prod"
}

Update Slack slash command with output URL

If you set up the Terraform module as above, the webhook URL should be output by Terraform after deployment. Head back to the slash command configuration page as before, but instead of creating a new command you can edit the command you made previously. Paste the webhook URL into the URL(s) field, hit save, and you're good to go!

terraform-aws-slack-pivotal-tracker-bot's People

Contributors

stangah avatar duncan-truss avatar

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.