Skip to content

Commit

Permalink
fix rbac
Browse files Browse the repository at this point in the history
  • Loading branch information
Telemaco019 committed Aug 7, 2024
1 parent 53e2597 commit dcdf1b4
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,9 +109,9 @@ Available on [Terraform Registry](https://registry.terraform.io/modules/nebuly-a
- resource.azurerm_role_assignment.aks_network_contributor (/terraform-docs/main.tf#613)
- resource.azurerm_role_assignment.key_vault_secret_officer__current (/terraform-docs/main.tf#220)
- resource.azurerm_role_assignment.key_vault_secret_user__aks (/terraform-docs/main.tf#215)
- resource.azurerm_role_assignment.storage_container_models__data_contributor (/terraform-docs/main.tf#514)
- resource.azurerm_storage_account.main (/terraform-docs/main.tf#490)
- resource.azurerm_storage_container.models (/terraform-docs/main.tf#510)
- resource.azurerm_role_assignment.storage_container_models__data_contributor (/terraform-docs/main.tf#512)
- resource.azurerm_storage_account.main (/terraform-docs/main.tf#488)
- resource.azurerm_storage_container.models (/terraform-docs/main.tf#508)
- resource.azurerm_subnet.aks_nodes (/terraform-docs/main.tf#127)
- resource.azurerm_subnet.flexible_postgres (/terraform-docs/main.tf#149)
- resource.azurerm_subnet.private_endpints (/terraform-docs/main.tf#141)
Expand Down
6 changes: 3 additions & 3 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -484,8 +484,6 @@ resource "azurerm_key_vault_secret" "azure_openai_api_key" {





# ------ Model Registry ------ #
resource "azurerm_storage_account" "main" {
name = format("%s%s", var.resource_prefix, "models")
Expand Down Expand Up @@ -513,11 +511,13 @@ resource "azurerm_storage_container" "models" {
}
resource "azurerm_role_assignment" "storage_container_models__data_contributor" {
role_definition_name = "Storage Blob Data Contributor"
principal_id = azuread_service_principal.main.object_id
principal_id = module.aks.kubelet_identity[0].object_id
scope = azurerm_storage_container.models.resource_manager_id
}




# ------ AKS ------ #
resource "tls_private_key" "aks" {
algorithm = "RSA" # Azure VMs currently do not support ECDSA
Expand Down
1 change: 1 addition & 0 deletions tests/dev-provisioning/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ provider "azurerm" {
subscription_id = var.subscription_id
}


# ------ Variables ------ #
variable "resource_prefix" {
type = string
Expand Down

0 comments on commit dcdf1b4

Please sign in to comment.