Blocking ec2:DescribeSpotPriceHistory on Elastic Agents causes Elastic Image configuration to fail with empty(NULL) Product field - rendering error on UI

XMLWordPrintable

    • Type: Bug
    • Resolution: Invalid
    • Priority: Low
    • None
    • Affects Version/s: 12.1.1
    • Component/s: Elastic Bamboo
    • None
    • 1
    • Severity 3 - Minor
    • 1

      Issue Summary

      Configuring an Elastic Image with spot-disabled EC2 agents but blocked ec2:DescribeSpotPriceHistory causes Bamboo to fail page rendering and leave the Product field to null.

      Steps to Reproduce

      1. Have selective IAM policies for the instance profile that runs on the EC2 instance of Bamboo
      2. Explicitly block ec2:DescribeSpotPriceHistory action in your IAM policy
      3. Disable spot instances (or simply don't use them)
      4. Try to configure an Elastic Image

      Expected Results

      Bamboo should ignore any spot requests or errors and continue rendeding the Image configuration normally.

      Actual Results

      • Logs report messages such as:
      Suppressed: software.amazon.awssdk.core.exception.SdkClientException: Request attempt 1 failure: You are not authorized to perform this operation. User: arn:aws:sts::693422065408:assumed-role/atlassian-uat-ec2-bamboo/i-04142193d55a669cb is not authorized to perform: ec2:DescribeSpotPriceHistory because no identity-based policy allows the ec2:DescribeSpotPriceHistory action (Service: Ec2, Status Code: 403, Request ID: 926c4c20-a3e2-4937-b4a0-4ae2ac827df3) 
      • When configuring an Elastic image the "Product" (EC2 Product name) field returns empty and when submitting the UI reports an error stating the field can't be null

      Workaround

      Allow ec2:DescribeSpotPriceHistory in the instance profile.

              Assignee:
              Mateusz Szmal
              Reporter:
              Alex (Inactive)
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: