Skip to content

Grunt to JIRA via Tasktop Gateway




Clear & Concise communication fosters effective collaboration.

Ensuring that all barriers to communication are removed should be a primary objective for all software development teams.

One approach is to ensure that all your tools are able to pass the right information at the right time when needed.

For many DevOps teams, a lot of time and resource is dedicated to writing scripts,  in order to integrate various tools via publicly exposed API's.   One of the obvious  areas of interest is within the Build and Deploy pipeline.

How do you feedback information to your developers that there has been a build or deployment failure, on a server ? Wouldn't it be great if you could get Grunt to raise a ticket in JIRA as and when an issue occurs.

Tasktop Sync Gateway enables teams to integrate a myriad of different tools by providing the ability to send JSON payloads of data to REST API endpoint.

In this following example, we'll raise a hypothetical error in Jira, with the intention of creating a task in Jira for a developer to investigate. I have intentionally kept this simple at this stage, for illustrations purposes

module.exports = function(grunt) {
    grunt.initConfig({
    pkg:grunt.file.readJSON('package.json'),
        http:{
            local:{
                options:{
                    url: 'http://192.168.137.133:10080/api/v1/artifacts/grunt',
                    json: {
                                "creator": "GruntUser",
                                "project": "Gateway Demo",
                                "summary": "Grunt build error report",
                                "type": "Task",
                                "description": "A test error from tasktop gateway & grunt",
                                "priority" : "Major"
                            },
                    method:'POST'
                        }
                    }
            }
    });
    
    grunt.loadNpmTasks('grunt-http');
    grunt.registerTask('default', ['http']);

};





Simply running the grunt file above will result a new issue being created in JIRA

[ebs_thumbnail target="_self" alt="JIRA Grunt Tasktop Gateway" src="https://garywoodfine.com/wp-content/uploads/2016/07/jira-1024x488.png"]

 

All this is made possible by utilising basic configuration of Tasktop Gateway

 




Latest posts by Gary Woodfine (see all)