6 Oct 2014 · Semaphore News

    Deploy from your chat room

    2 min read
    Contents

    Remember how excited you were when Jesse Newland from GitHub presented ChatOps at GitHub? Great news! From now on you can set up your own Hubot to perform deployments on Semaphore.

    Several weeks ago Ben Straub from Gridium asked us about a way to trigger a deploy via Semaphore API. We exchanged several mails and as a result he sent us a Hubot script to run a deploy on Semaphore. On the screenshot below you can see it in action as one of the founders from Gridium deploys a project to production right from a Slack chat room.

    Deploying to production with Semaphore from a Slack chat room

    How to set up Hubot

    Hubot — GitHub’s chat bot — is a friendly robot that lives in your chat room and helps you and your team with simple tasks.

    It can be deployed on a wide variety of platforms, including Linux and Windows, but a popular option is to deploy it to
    Heroku. Detailed instructions about installation can be found in Hubot’s Readme file.

    After deployment you need to invite the bot in your chat room. Hubot has simple integration with popular chat services such as Slack and Campfire, but it can also work on many other chat services.

    Make your Hubot work with Semaphore

    In order to extend your own Hubot with the deployment feature, please clone the hubot-semaphore-deploy repository and follow the tutorial in Hubot’s Readme on adding scripts.

    After installing the script you will need to copy the API auth token from Semaphore and export it in your Hubot’s production environment. The auth token can be found in your project’s setting under the API tab.

    sh
    export HUBOT_SEMAPHOREAPP_AUTH_TOKEN=
    

    And that’s all there is to have deploy power right in your chat room. Having this feature in your company’s workflow can increase awareness of what everyone is working on, and also reduce the time newcomers need to get up to speed with the process of continuous integration and delivery.

    Update: Ben Straub joined forces with the author of hubot-semaphoreapp and combined this project with Semaphore status updates.

    Leave a Reply

    Your email address will not be published. Required fields are marked *

    Avatar
    Writen by:
    Chief Architect at Semaphore. A decade of experience in dev productivity, helping close to 50,000 organizations with operational excellence.