This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Original Gist published by dennis-tra | |
//https://gist.github.com/dennis-tra/ae0dacbab1576d956bf62b4ab2209f5b | |
exports.handler = (event, context, callback) => { | |
var aws = require('aws-sdk'); | |
aws.config.update({region: process.env.ECS_REGION}); | |
var ecs = new aws.ECS(); | |
//Fetching last Task Definition | |
ecs.describeTaskDefinition({ taskDefinition: process.env.ECS_TASK_NAME }, function(err, data) { |