baked in cloud formation template
parent
ae4d84f7f6
commit
09c6df818f
|
|
@ -2011,10 +2011,6 @@ class AwsCliCommands {
|
|||
const stacks = ((_a = (yield CF.listStacks().promise()).StackSummaries) === null || _a === void 0 ? void 0 : _a.filter((_x) => _x.StackStatus !== 'DELETE_COMPLETE')) || [];
|
||||
for (const element of stacks) {
|
||||
cloud_runner_logger_1.default.log(JSON.stringify(element, undefined, 4));
|
||||
if (element.StackName === 'game-ci' || element.TemplateDescription === 'Game-CI base stack') {
|
||||
cloud_runner_logger_1.default.log(`Skipping ${element.StackName} ignore list`);
|
||||
continue;
|
||||
}
|
||||
cloud_runner_logger_1.default.log(`${element.StackName}`);
|
||||
perResultCallback(element);
|
||||
}
|
||||
|
|
@ -2082,6 +2078,10 @@ class AwsCliCommands {
|
|||
AwsCliCommands.awsListStacks((element) => __awaiter(this, void 0, void 0, function* () {
|
||||
if (deleteResources &&
|
||||
new Date(Date.now()).getUTCMilliseconds() - element.CreationTime.getUTCMilliseconds() > olderThanAgeInHours) {
|
||||
if (element.StackName === 'game-ci' || element.TemplateDescription === 'Game-CI base stack') {
|
||||
cloud_runner_logger_1.default.log(`Skipping ${element.StackName} ignore list`);
|
||||
return;
|
||||
}
|
||||
const deleteStackInput = { StackName: element.StackName };
|
||||
yield CF.deleteStack(deleteStackInput).promise();
|
||||
}
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
|
|
@ -12,10 +12,6 @@ export class AwsCliCommands {
|
|||
(await CF.listStacks().promise()).StackSummaries?.filter((_x) => _x.StackStatus !== 'DELETE_COMPLETE') || [];
|
||||
for (const element of stacks) {
|
||||
CloudRunnerLogger.log(JSON.stringify(element, undefined, 4));
|
||||
if (element.StackName === 'game-ci' || element.TemplateDescription === 'Game-CI base stack') {
|
||||
CloudRunnerLogger.log(`Skipping ${element.StackName} ignore list`);
|
||||
continue;
|
||||
}
|
||||
CloudRunnerLogger.log(`${element.StackName}`);
|
||||
perResultCallback(element);
|
||||
}
|
||||
|
|
@ -81,6 +77,11 @@ export class AwsCliCommands {
|
|||
deleteResources &&
|
||||
new Date(Date.now()).getUTCMilliseconds() - element.CreationTime.getUTCMilliseconds() > olderThanAgeInHours
|
||||
) {
|
||||
if (element.StackName === 'game-ci' || element.TemplateDescription === 'Game-CI base stack') {
|
||||
CloudRunnerLogger.log(`Skipping ${element.StackName} ignore list`);
|
||||
|
||||
return;
|
||||
}
|
||||
const deleteStackInput: AWS.CloudFormation.DeleteStackInput = { StackName: element.StackName };
|
||||
await CF.deleteStack(deleteStackInput).promise();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue