Add S3 bucket and policy configuration for Grafana integration#22
Open
whatislavx wants to merge 1 commit into
Open
Add S3 bucket and policy configuration for Grafana integration#22whatislavx wants to merge 1 commit into
whatislavx wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
Pull request overview
Adds the Terraform resources and inputs needed to provision an S3 bucket for Grafana and attach a bucket policy granting the Grafana IAM role access.
Changes:
- Added
aws_s3_bucket,aws_s3_bucket_policy, and anaws_iam_policy_documentwith the required two statements. - Introduced new input variables for bucket name/tags and updated outputs to reference the new bucket resource.
- Updated
terraform.tfvarsand committed a generatedtfplan.jsonreflecting the new infrastructure plan.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
main.tf |
Creates the S3 bucket and bucket policy allowing the Grafana IAM role to list the bucket and read/write objects. |
variables.tf |
Defines new variables for bucket_name and bucket_tags (and reformats the existing IAM role variable). |
outputs.tf |
Fixes the output to reference aws_s3_bucket.backups_bucket. |
terraform.tfvars |
Provides concrete values for the newly added variables and the Grafana IAM role ARN. |
tfplan.json |
Captures the Terraform plan JSON showing the bucket and policy creation. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
| type = string | ||
| description = "" | ||
| type = string | ||
| description = "" |
Comment on lines
+9
to
+12
| policy = data.aws_iam_policy_document.policy-document.json | ||
| } | ||
|
|
||
| data "aws_iam_policy_document" "policy-document" { |
| # 2. Confugure bucket policy to allow grafana iam role to use storage | ||
| tags = var.bucket_tags | ||
| } | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.