community icon indicating copy to clipboard operation
community copied to clipboard

`Instance` resource contains ACK Service Tags in `Spec.Tags` upon creation

Open brycahta opened this issue 1 year ago • 1 comments

Describe the bug I create an Instance tagged with producer: ACK via ec2-controller and when I inspect the resource Spec.Tags contains 3 tags, ACK Service tags + my tag:

  Tags:
    Key:    services.k8s.aws/controller-version
    Value:  ec2-unknown
    Key:    producer
    Value:  ack
    Key:    services.k8s.aws/namespace
    Value:  default

Steps to reproduce

  • run ec2-controller v0.0.20 or later
  • kubectl apply -f instance-test.yaml
  • kubectl describe instances

Expected outcome Spec.Tags should never include ACK Service tags:

  Tags:
    Key:    producer
    Value:  ack

Environment

  • Kubernetes version: 1.22
  • Using EKS (yes/no), if so version: eks.11
  • AWS service targeted (S3, RDS, etc.): ec2-controller v0.0.20 or later

brycahta avatar Sep 28 '22 16:09 brycahta

related: https://github.com/aws-controllers-k8s/community/issues/1291

brycahta avatar Sep 28 '22 16:09 brycahta

Resolved after introducing a workaround to maintain Tags order and refactoring Tags e2e test to validate service tags are NOT in the Spec

brycahta avatar Oct 12 '22 15:10 brycahta