Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update-task-definition command remove the runtime-platform information #137

Closed
yyamada-red-frasco opened this issue Dec 7, 2021 · 4 comments · Fixed by #155
Closed

update-task-definition command remove the runtime-platform information #137

yyamada-red-frasco opened this issue Dec 7, 2021 · 4 comments · Fixed by #155
Assignees
Labels
bug Something isn't working

Comments

@yyamada-red-frasco
Copy link

Orb version:

2.2.1

What happened:

The runtime-platform parameter is not specified in the aws ecs register-task-definition of the update-task-definition command, so if you update the task definition that specifies the runtime-platform, the information will be removed.
https://docs.aws.amazon.com/cli/latest/reference/ecs/register-task-definition.html

Steps:

  • create a task definition with this value set:
"runtimePlatform": {
  "operatingSystemFamily": "LINUX",
  "cpuArchitecture": "ARM64"
}
  • use the orb to update the task definition
    aws-ecs/update-task-definition

Expected behavior:

Update the task definition with the runtime-platform information specified in the existing task definition.

Additional Information:

The current aws ecs describe-task-definition cannot get the runtime-platform information.
Therefore, until AWS updates it, you need to add cpuArchitecture and operatingSystemFamily to the Orb command parameters.

@yyamada-red-frasco yyamada-red-frasco added the bug Something isn't working label Dec 7, 2021
@alansikora
Copy link

At least on the latest version, it does retrieve runtimePlatform.

{
    "taskDefinition": {
        "taskDefinitionArn": "------",
        "containerDefinitions": [
            {
                "name": "------",
                "image": "------",
                "cpu": 0,
                "portMappings": [
                    {
                        "containerPort": ------,
                        "hostPort": ------,
                        "protocol": "------"
                    }
                ],
                "essential": true,
                "environment": [],
                "mountPoints": [],
                "volumesFrom": [],
                "logConfiguration": {
                    "logDriver": "awslogs",
                    "options": {
                        "awslogs-create-group": "true",
                        "awslogs-group": "------",
                        "awslogs-region": "------",
                        "awslogs-stream-prefix": "------"
                    }
                }
            }
        ],
        "family": "------",
        "executionRoleArn": "------",
        "networkMode": "awsvpc",
        "revision": 24,
        "volumes": [],
        "status": "ACTIVE",
        "requiresAttributes": [
            {
                "name": "com.amazonaws.ecs.capability.logging-driver.awslogs"
            },
            {
                "name": "ecs.capability.execution-role-awslogs"
            },
            {
                "name": "com.amazonaws.ecs.capability.ecr-auth"
            },
            {
                "name": "com.amazonaws.ecs.capability.docker-remote-api.1.19"
            },
            {
                "name": "ecs.capability.execution-role-ecr-pull"
            },
            {
                "name": "com.amazonaws.ecs.capability.docker-remote-api.1.18"
            },
            {
                "name": "ecs.capability.task-eni"
            },
            {
                "name": "com.amazonaws.ecs.capability.docker-remote-api.1.29"
            }
        ],
        "placementConstraints": [],
        "compatibilities": [
            "EC2",
            "FARGATE"
        ],
        "runtimePlatform": {
            "cpuArchitecture": "ARM64",
            "operatingSystemFamily": "LINUX"
        },
        "requiresCompatibilities": [
            "FARGATE"
        ],
        "cpu": "256",
        "memory": "512",
        "registeredAt": "2022-01-03T08:48:37.363000-03:00",
        "registeredBy": "arn:aws:iam::425675427949:user/cli"
    },
    "tags": [
        {
            "key": "Environment",
            "value": "production"
        }
    ]
}

@alansikora
Copy link

I was planning on adding the support, but I'm on a very hectic moment of my project right now, so I won't be able to.

But if nobody adds the new code when I'm free again, I will work on adding the support.

ddemydenko added a commit to ddemydenko/aws-ecs-orb that referenced this issue Jan 18, 2022
ddemydenko added a commit to ddemydenko/aws-ecs-orb that referenced this issue Jan 19, 2022
…platform-parameter

fix issue CircleCI-Public#137: add runtimePlatform to the Orb command parameters.
@maxcrossan
Copy link

Would be great to have this in 2.2.2

@yoavya
Copy link

yoavya commented Apr 10, 2022

Is there a workaround for this besides copying the code to my circle configuration file and fixing the issue locally? Or is there any ETA on the release @alansikora ?

@brivu brivu self-assigned this May 19, 2022
@brivu brivu linked a pull request May 19, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
5 participants