Skip to content

Commit

Permalink
feat: Release v1.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Aug 18, 2023
1 parent 0e1bc77 commit 081f938
Showing 1 changed file with 13 additions and 26 deletions.
39 changes: 13 additions & 26 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -25778,7 +25778,7 @@ var require_ListTaskDefinitionsCommand = __commonJS({
return smithy_client_1.Command;
} });
var Aws_json1_1_1 = require_Aws_json1_1();
var ListTaskDefinitionsCommand2 = class _ListTaskDefinitionsCommand extends smithy_client_1.Command {
var ListTaskDefinitionsCommand = class _ListTaskDefinitionsCommand extends smithy_client_1.Command {
static getEndpointParameterInstructions() {
return {
UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
Expand Down Expand Up @@ -25815,7 +25815,7 @@ var require_ListTaskDefinitionsCommand = __commonJS({
return (0, Aws_json1_1_1.de_ListTaskDefinitionsCommand)(output, context);
}
};
exports.ListTaskDefinitionsCommand = ListTaskDefinitionsCommand2;
exports.ListTaskDefinitionsCommand = ListTaskDefinitionsCommand;
}
});

Expand Down Expand Up @@ -28167,31 +28167,18 @@ var getInputRequired = (name) => (0, import_core.getInput)(name, {
let taskDefinition = {};
let tags;
await (0, import_core.group)("Fetching latest revision of the task definition", async () => {
{
const response = await client.send(
new import_client_ecs.ListTaskDefinitionsCommand({
familyPrefix: family,
sort: "DESC"
})
);
const taskDefinitionArns = response.taskDefinitionArns ?? [];
if (taskDefinitionArns.length < 1) {
throw new Error("The family has no task definitions.");
}
oldTaskDefinitionArn = taskDefinitionArns[0];
}
{
const response = await client.send(
new import_client_ecs.DescribeTaskDefinitionCommand({
taskDefinition: oldTaskDefinitionArn
})
);
if (!response.taskDefinition) {
throw new Error("The task definition can not be retrieved.");
}
taskDefinition = response.taskDefinition;
tags = response.tags;
const response = await client.send(
new import_client_ecs.DescribeTaskDefinitionCommand({
include: ["TAGS"],
taskDefinition: family
})
);
if (!response.taskDefinition || !response.taskDefinition.taskDefinitionArn) {
throw new Error("The task definition can not be retrieved.");
}
oldTaskDefinitionArn = response.taskDefinition.taskDefinitionArn;
taskDefinition = response.taskDefinition;
tags = response.tags;
console.log(`\u2705 Fetched latest task definition: ${oldTaskDefinitionArn}`);
});
await (0, import_core.group)("Current task definition", async () => {
Expand Down

0 comments on commit 081f938

Please sign in to comment.