Skip to content

Commit

Permalink
fix: removing bucket name ver references (#8)
Browse files Browse the repository at this point in the history
Co-authored-by: Werner Matias Kahnlein <[email protected]>
  • Loading branch information
werner-nops and mkahnlein-caylent authored Nov 12, 2024
1 parent ba80751 commit e17f24d
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ No modules.
| <a name="input_api_key"></a> [api\_key](#input\_api\_key) | [DEPRECATED] The nOps API key, can be supplied as an env var NOPS\_API\_KEY or in the provider call in your configuration. | `string` | `""` | no |
| <a name="input_min_required_permissions"></a> [min\_required\_permissions](#input\_min\_required\_permissions) | If true, IAM policies with the min base permissions for nOps to get cost and usage data will be created. Some platform features will not be available. | `bool` | `false` | no |
| <a name="input_reconfigure"></a> [reconfigure](#input\_reconfigure) | [DEPRECATED] If true, allows overriding existing project settings. If false, stops execution if project already exists. | `bool` | `false` | no |
| <a name="input_system_bucket_name"></a> [system\_bucket\_name](#input\_system\_bucket\_name) | The name of the system bucket for nOps integration, this will be deprecated in the future. Keeping for backwards compatibility. | `string` | `"na"` | no |
| <a name="input_system_bucket_name"></a> [system\_bucket\_name](#input\_system\_bucket\_name) | [DEPRECATED] The name of the system bucket for nOps integration. | `string` | `"na"` | no |

## Outputs

Expand Down
2 changes: 1 addition & 1 deletion iam.tf
Original file line number Diff line number Diff line change
Expand Up @@ -519,7 +519,7 @@ resource "aws_iam_role_policy" "nops_integration_policy" {
}

resource "aws_iam_role_policy" "nops_system_bucket_policy" {
count = local.is_master_account && local.system_bucket_name != "na" ? 1 : 0
count = local.create_bucket ? 1 : 0
name = "NopsSystemBucketPolicy"
role = aws_iam_role.nops_integration_role.id

Expand Down
2 changes: 1 addition & 1 deletion locals.tf
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ locals {
client_id = nops_project.project.id
project_id = nops_project.project.client
external_id = nops_project.project.external_id
system_bucket_name = var.system_bucket_name != "na" ? var.system_bucket_name : "nops-${local.client_id}-${local.project_id}-${local.account_id}"
system_bucket_name = "nops-${local.client_id}-${local.project_id}-${local.account_id}"
create_bucket = local.is_master_account
}
3 changes: 2 additions & 1 deletion variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@ variable "min_required_permissions" {
description = "If true, IAM policies with the min base permissions for nOps to get cost and usage data will be created. Some platform features will not be available."
}

# tflint-ignore: terraform_unused_declarations
variable "system_bucket_name" {
type = string
default = "na"
description = "The name of the system bucket for nOps integration, this will be deprecated in the future. Keeping for backwards compatibility."
description = "[DEPRECATED] The name of the system bucket for nOps integration."
}

# tflint-ignore: terraform_unused_declarations
Expand Down

0 comments on commit e17f24d

Please sign in to comment.