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

Print link to logs #7

Open
vladimir-cageyv-firi opened this issue Apr 29, 2022 · 2 comments
Open

Print link to logs #7

vladimir-cageyv-firi opened this issue Apr 29, 2022 · 2 comments
Labels
help wanted Extra attention is needed

Comments

@vladimir-cageyv-firi
Copy link

No description provided.

@cageyv
Copy link
Member

cageyv commented Jan 16, 2024

Task Event Example from AWS
https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs_cwe_events.html#ecs_task_events
The problem was: Inside that event we don’t have direct information about logging config

But we could use taskDefinitionArn and by that value lookup for log config
API_DescribeTaskDefinition could give us logConfiguration
And if logDriver = awslogs we could get all options and generate CloudWatch URL

  log_configuration = {
    "logDriver" : "awslogs",
    "options" : {
      "awslogs-group" : aws_cloudwatch_log_group.this.name,
      "awslogs-region" : data.aws_region.current.name,
      "awslogs-stream-prefix" : "/${var.service_name}"
    }
  }

Or probably it is possible to get from task itself, but I assume that Task could be killed and not exist at the moment of the event.

@cageyv
Copy link
Member

cageyv commented Jan 16, 2024

DescribeTaskDefinition will require additional IAM permissions
But we could solve that

@cageyv cageyv added the help wanted Extra attention is needed label Jan 16, 2024
@cageyv cageyv moved this from Icebox to Backlog in Open source Jan 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
Status: Backlog
Development

No branches or pull requests

2 participants