Skip to content

Commit eb74afd

Browse files
committed
feat: grant admin consent for delegated permission in sso module
1 parent a69615e commit eb74afd

File tree

5 files changed

+16
-9
lines changed

5 files changed

+16
-9
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,8 +179,8 @@ Before opening a Pull Request, please do the following:
179179

180180
| Name | Version |
181181
|------|---------|
182-
| <a name="provider_azuread"></a> [azuread](#provider\_azuread) | 2.53.1 |
183-
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.114.0 |
182+
| <a name="provider_azuread"></a> [azuread](#provider\_azuread) | 3.0.2 |
183+
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 4.5.0 |
184184

185185
## Modules
186186

modules/meshcloud-metering-service-principal/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111

1212
| Name | Version |
1313
|------|---------|
14-
| <a name="provider_azuread"></a> [azuread](#provider\_azuread) | 2.53.1 |
15-
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.114.0 |
16-
| <a name="provider_time"></a> [time](#provider\_time) | 0.12.0 |
14+
| <a name="provider_azuread"></a> [azuread](#provider\_azuread) | 3.0.2 |
15+
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 4.5.0 |
16+
| <a name="provider_time"></a> [time](#provider\_time) | 0.12.1 |
1717

1818
## Modules
1919

modules/meshcloud-replicator-service-principal/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@
1111

1212
| Name | Version |
1313
|------|---------|
14-
| <a name="provider_azuread"></a> [azuread](#provider\_azuread) | 2.53.1 |
15-
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.114.0 |
14+
| <a name="provider_azuread"></a> [azuread](#provider\_azuread) | 3.0.2 |
15+
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 4.5.0 |
1616
| <a name="provider_terraform"></a> [terraform](#provider\_terraform) | n/a |
17-
| <a name="provider_time"></a> [time](#provider\_time) | 0.12.0 |
17+
| <a name="provider_time"></a> [time](#provider\_time) | 0.12.1 |
1818

1919
## Modules
2020

modules/meshcloud-sso/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
| Name | Version |
1212
|------|---------|
13-
| <a name="provider_azuread"></a> [azuread](#provider\_azuread) | 2.53.1 |
13+
| <a name="provider_azuread"></a> [azuread](#provider\_azuread) | 3.0.2 |
1414

1515
## Modules
1616

@@ -23,6 +23,7 @@ No modules.
2323
| [azuread_application.meshcloud_sso](https://registry.terraform.io/providers/hashicorp/azuread/latest/docs/resources/application) | resource |
2424
| [azuread_application_password.meshcloud_sso](https://registry.terraform.io/providers/hashicorp/azuread/latest/docs/resources/application_password) | resource |
2525
| [azuread_service_principal.meshcloud_sso](https://registry.terraform.io/providers/hashicorp/azuread/latest/docs/resources/service_principal) | resource |
26+
| [azuread_service_principal_delegated_permission_grant.meshcloud_sso](https://registry.terraform.io/providers/hashicorp/azuread/latest/docs/resources/service_principal_delegated_permission_grant) | resource |
2627
| [azuread_application_published_app_ids.well_known](https://registry.terraform.io/providers/hashicorp/azuread/latest/docs/data-sources/application_published_app_ids) | data source |
2728
| [azuread_application_template.enterprise_app](https://registry.terraform.io/providers/hashicorp/azuread/latest/docs/data-sources/application_template) | data source |
2829
| [azuread_client_config.current](https://registry.terraform.io/providers/hashicorp/azuread/latest/docs/data-sources/client_config) | data source |

modules/meshcloud-sso/module.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,3 +61,9 @@ resource "azuread_service_principal" "meshcloud_sso" {
6161
resource "azuread_application_password" "meshcloud_sso" {
6262
application_id = azuread_application.meshcloud_sso.id
6363
}
64+
65+
resource "azuread_service_principal_delegated_permission_grant" "meshcloud_sso" {
66+
service_principal_object_id = azuread_service_principal.meshcloud_sso.object_id
67+
resource_service_principal_object_id = data.azuread_service_principal.msgraph.object_id
68+
claim_values = ["User.Read"]
69+
}

0 commit comments

Comments
 (0)