File tree 1 file changed +10
-1
lines changed
1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -132,7 +132,7 @@ async function run() {
132
132
133
133
// Register the task definition if necessary - or use the passed in ARN
134
134
if (!taskDefinitionFile && !taskDefRevisionArn) {
135
- const msg = "Invalid parameters: One of task-definition-file or task-definition-arn must be set";
135
+ const msg = "Invalid parameters: One of task-definition or task-definition-revision -arn must be set";
136
136
core.setFailed(msg);
137
137
throw new Error(msg);
138
138
}
@@ -163,8 +163,17 @@ async function run() {
163
163
} else {
164
164
core.debug(`Using the passed task definition ARN ${taskDefRevisionArn}`);
165
165
}
166
+
166
167
core.setOutput('task-definition-arn', taskDefRevisionArn);
167
168
169
+ /* Extract task-definition-family & revision ARN, so we can output family:revision
170
+ * Useful for later using `aws ecs describe-task-definition` to get the full ARN,
171
+ * since outputting full ARN can be misinterpreted as a secret by Github Actions.
172
+ */
173
+ const regex = new RegExp(':task-definition/(.*)$');
174
+ const matches = taskDefRevisionArn.match(regex);
175
+ core.setOutput('task-definition-family-and-revision', matches[1])
176
+
168
177
const clusterName = cluster ? cluster : 'default';
169
178
170
179
/**
You can’t perform that action at this time.
0 commit comments