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

feat: add dynamic s3Locations statements to allow oidc roles access to specified s3 paths #6567

Merged

Conversation

tom-webber
Copy link
Contributor

@tom-webber tom-webber commented Jan 16, 2025

Pull Request Objective

This piece of work is being tracked in #4622.

#4622 involves switching over workflow processes to run on GitHub Actions runners assuming roles by OIDC (roles specified in the files edited in this PR) rather than running on self-hosted runners (see this PR for an example). In order to do this, the new OIDC roles need permissions to be able to carry out all of the duties of the existing roles.

A change is required to allow the analytics-platform-helm-charts role to deposit artefacts (which fails without this change) in s3. This is separate from the requirement for state bucket access, so a key:value pair was added to the oidc-roles json that creates a dynamic statement in the github_oidc_role for each role.

Checklist

  • I have reviewed the style guide
    and ensured that my code complies with it
  • All checks have passed (or override label applied, if I've
    used the override-static-analysis label, I've explained why)
  • I have self-reviewed my code
  • I have reviewed the checks and can attest they're as expected

Additional Comments

… to specified s3 paths

Required for `analytics-platform-helm-charts` role to deposit artefacts
@tom-webber tom-webber requested a review from a team as a code owner January 16, 2025 10:42
Copy link
Contributor

github-actions bot commented Jan 16, 2025

Terraform Component 🧱: aws-analytical-platform-oidc

Checkov 🛂: success

Trivy 🛂: success

Static Analysis Override Label 🏷️: false

Pusher: @tom-webber, Action: pull_request, Working Directory: terraform/aws/analytical-platform/oidc, Workflow: Terraform, Marker: aws-analytical-platform-oidc_static_analysis

Copy link
Contributor

github-actions bot commented Jan 16, 2025

Terraform Component 🧱: aws-analytical-platform-oidc

Terraform Initialization ⚙️: success

Terraform Validation 🤖: success

Terraform Plan 🛠️: success

Pusher: @tom-webber, Action: pull_request, Working Directory: terraform/aws/analytical-platform/oidc, Workflow: Terraform, Marker: aws-analytical-platform-oidc_plan

Copy link
Contributor

@julialawrence julialawrence left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@tom-webber tom-webber merged commit f4bd0de into main Jan 16, 2025
21 checks passed
@tom-webber tom-webber deleted the feat/AP-4622-add-dynamic-s3-policy-to-assumable-oidc-roles branch January 16, 2025 11:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants