Skip to content

Commit

Permalink
add systemControls to omit key
Browse files Browse the repository at this point in the history
  • Loading branch information
Claude-GP committed May 8, 2024
1 parent d42b26e commit 50394b2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/build-task-definition.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ get_task_definition() {
task_name=$1

# Thoses keys are returned by the Amazon ECS DescribeTaskDefinition, but are not valid fields when registering a new task definition
keys_to_omit=".compatibilities, .taskDefinitionArn, .requiresAttributes, .revision, .status, .registeredBy, .registeredAt"
keys_to_omit=".compatibilities, .taskDefinitionArn, .requiresAttributes, .revision, .status, .registeredBy, .registeredAt, .containerDefinitions[].systemControls"

returned_task_definition=$(aws ecs describe-task-definition --task-definition "${task_name}" | jq .taskDefinition | jq "del($keys_to_omit)")
if [ -z "${returned_task_definition}" ]; then
Expand Down

0 comments on commit 50394b2

Please sign in to comment.