in pipeline/local_modules/cloudformation/cloudformation_manager.js [75:92]
CloudFormationManager.prototype.getStackStatus = function (stackName) {
var self = this;
return self.getCloudFormationClient()
.then(function (cloudformationClient) {
var params = {
StackName: stackName
};
console.log("Checking stack status: " + JSON.stringify(params) + "...");
return cloudformationClient.describeStacks(params).promise();
})
.then(function (stacksData) {
return stacksData['Stacks'][0].StackStatus;
})
.catch(function(err) {
console.log("Got an error while checking stack status. Maybe stack does not exist? Error: " + err.message);
return STACK_DOES_NOT_EXIST;
});
}