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

Testing module branch #111

Closed
wants to merge 1 commit into from
Closed

Testing module branch #111

wants to merge 1 commit into from

Conversation

cpareek
Copy link
Contributor

@cpareek cpareek commented Feb 21, 2024

Jira link (if applicable)

https://tools.hmcts.net/jira/browse/DTSPO-16745

Change description

Testing module branch to see if the alert name change

Copy link
Contributor

hmcts-jenkins-cnp bot commented Feb 21, 2024

Plan Result

⚠️ Resource Deletion will happen ⚠️

This plan contains resource delete operation. Please check the plan result very carefully!

Plan: 7 to add, 5 to change, 1 to destroy.
  • Create
    • azurerm_key_vault_secret.appInsights-InstrumentationKey
    • module.vault.azurerm_key_vault_access_policy.creator_access_policy
    • module.vault.azurerm_key_vault_access_policy.developer[0]
    • module.vault.azurerm_key_vault_access_policy.managed_identity_access_policy["60ab1441-a8a9-4990-aa30-c94e9f0b047b"]
    • module.vault.azurerm_key_vault_access_policy.product_team_access_policy
    • module.vault.azurerm_monitor_diagnostic_setting.kv-ds
  • Update
    • azurerm_resource_group.shared_resource_group
    • module.application_insights.azurerm_application_insights.this
    • module.servicebus-namespace.azurerm_servicebus_namespace.servicebus_namespace
    • module.vault.azurerm_key_vault.kv
    • module.vault.azurerm_user_assigned_identity.managed_identity[0]
  • Replace
    • module.application_insights.azurerm_monitor_activity_log_alert.main
Change Result (Click me)
  # azurerm_key_vault_secret.appInsights-InstrumentationKey will be created
  + resource "azurerm_key_vault_secret" "appInsights-InstrumentationKey" {
      + id                      = (known after apply)
      + key_vault_id            = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/apple-shared-infrastructure-sbox/providers/Microsoft.KeyVault/vaults/applesi-sbox"
      + name                    = "appInsights-InstrumentationKey"
      + resource_id             = (known after apply)
      + resource_versionless_id = (known after apply)
      + value                   = (sensitive value)
      + version                 = (known after apply)
      + versionless_id          = (known after apply)
    }

  # azurerm_resource_group.shared_resource_group will be updated in-place
  ~ resource "azurerm_resource_group" "shared_resource_group" {
        id       = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/apple-shared-infrastructure-sbox"
        name     = "apple-shared-infrastructure-sbox"
      ~ tags     = {
            "application"         = "core"
            "autoShutdown"        = "true"
            "builtFrom"           = "https://github.com/HMCTS/sds-toffee-shared-infrastructure.git"
            "businessArea"        = "Cross-Cutting"
            "contactSlackChannel" = "#platops-help"
            "environment"         = "sandbox"
          ~ "expiresAfter"        = "2024-03-20" -> "3000-01-01"
            "managedBy"           = "Platform Operations"
            "startupMode"         = "onDemand"
        }
        # (1 unchanged attribute hidden)
    }

  # module.application_insights.azurerm_application_insights.this will be updated in-place
  ~ resource "azurerm_application_insights" "this" {
        id                                    = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/apple-shared-infrastructure-sbox/providers/Microsoft.Insights/components/apple-sbox"
        name                                  = "apple-sbox"
      ~ tags                                  = {
            "application"         = "core"
            "autoShutdown"        = "true"
            "builtFrom"           = "https://github.com/HMCTS/sds-toffee-shared-infrastructure.git"
            "businessArea"        = "Cross-Cutting"
            "contactSlackChannel" = "#platops-help"
            "environment"         = "sandbox"
          ~ "expiresAfter"        = "2024-03-20" -> "3000-01-01"
            "managedBy"           = "Platform Operations"
            "startupMode"         = "onDemand"
        }
        # (16 unchanged attributes hidden)
    }

  # module.application_insights.azurerm_monitor_activity_log_alert.main must be replaced
-/+ resource "azurerm_monitor_activity_log_alert" "main" {
      ~ id                  = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/apple-shared-infrastructure-sbox/providers/Microsoft.Insights/activityLogAlerts/Application Insights daily cap reached" -> (known after apply)
      ~ name                = "Application Insights daily cap reached" -> "Application Insights daily cap reached - apple-sbox" # forces replacement
      ~ tags                = {
            "application"         = "core"
            "autoShutdown"        = "true"
            "builtFrom"           = "https://github.com/HMCTS/sds-toffee-shared-infrastructure.git"
            "businessArea"        = "Cross-Cutting"
            "contactSlackChannel" = "#platops-help"
            "environment"         = "sandbox"
          ~ "expiresAfter"        = "2024-03-20" -> "3000-01-01"
            "managedBy"           = "Platform Operations"
            "startupMode"         = "onDemand"
        }
        # (4 unchanged attributes hidden)

      ~ action {
          ~ action_group_id    = "/subscriptions/6c4d2513-a873-41b4-afdd-b05a33206631/resourceGroups/sds-alerts-slack-ptl/providers/Microsoft.Insights/actionGroups/sds-alerts-slack-warning-alerts" -> "/subscriptions/6c4d2513-a873-41b4-afdd-b05a33206631/resourceGroups/sds-alerts-slack-ptl/providers/Microsoft.Insights/actiongroups/sds-alerts-slack-warning-alerts"
            # (1 unchanged attribute hidden)
        }

      ~ criteria {
          - levels             = [] -> null
          - resource_groups    = [] -> null
          - resource_ids       = [] -> null
          - resource_providers = [] -> null
          - resource_types     = [] -> null
          - statuses           = [] -> null
          - sub_statuses       = [] -> null
            # (4 unchanged attributes hidden)
        }
    }

  # module.servicebus-namespace.azurerm_servicebus_namespace.servicebus_namespace will be updated in-place
  ~ resource "azurerm_servicebus_namespace" "servicebus_namespace" {
        id                                  = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/apple-shared-infrastructure-sbox/providers/Microsoft.ServiceBus/namespaces/apple-servicebus-sbox"
        name                                = "apple-servicebus-sbox"
      ~ tags                                = {
            "application"         = "core"
            "autoShutdown"        = "true"
            "builtFrom"           = "https://github.com/HMCTS/sds-toffee-shared-infrastructure.git"
            "businessArea"        = "Cross-Cutting"
            "contactSlackChannel" = "#platops-help"
            "environment"         = "sandbox"
          ~ "expiresAfter"        = "2024-03-20" -> "3000-01-01"
            "managedBy"           = "Platform Operations"
            "startupMode"         = "onDemand"
        }
        # (13 unchanged attributes hidden)

        # (1 unchanged block hidden)
    }

  # module.vault.azurerm_key_vault.kv will be updated in-place
  ~ resource "azurerm_key_vault" "kv" {
        id                              = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/apple-shared-infrastructure-sbox/providers/Microsoft.KeyVault/vaults/applesi-sbox"
        name                            = "applesi-sbox"
      ~ tags                            = {
            "application"         = "core"
            "autoShutdown"        = "true"
            "builtFrom"           = "https://github.com/HMCTS/sds-toffee-shared-infrastructure.git"
            "businessArea"        = "Cross-Cutting"
            "contactSlackChannel" = "#platops-help"
            "environment"         = "sandbox"
          ~ "expiresAfter"        = "2024-03-20" -> "3000-01-01"
            "managedBy"           = "Platform Operations"
            "startupMode"         = "onDemand"
        }
        # (13 unchanged attributes hidden)

        # (1 unchanged block hidden)
    }

  # module.vault.azurerm_key_vault_access_policy.creator_access_policy will be created
  + resource "azurerm_key_vault_access_policy" "creator_access_policy" {
      + certificate_permissions = [
          + "Create",
          + "Delete",
          + "DeleteIssuers",
          + "Get",
          + "GetIssuers",
          + "Import",
          + "List",
          + "ListIssuers",
          + "SetIssuers",
          + "Update",
          + "ManageContacts",
          + "ManageIssuers",
        ]
      + id                      = (known after apply)
      + key_permissions         = [
          + "Create",
          + "List",
          + "Get",
          + "Delete",
          + "Update",
          + "Import",
          + "Backup",
          + "Restore",
          + "Decrypt",
          + "Encrypt",
          + "UnwrapKey",
          + "WrapKey",
          + "Sign",
          + "Verify",
          + "GetRotationPolicy",
        ]
      + key_vault_id            = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/apple-shared-infrastructure-sbox/providers/Microsoft.KeyVault/vaults/applesi-sbox"
      + object_id               = "5356a0e7-324e-4efa-970b-4b4aec3f0ba3"
      + secret_permissions      = [
          + "Set",
          + "List",
          + "Get",
          + "Delete",
          + "Recover",
          + "Purge",
        ]
      + tenant_id               = "531ff96d-0ae9-462a-8d2d-bec7c0b42082"
    }

  # module.vault.azurerm_key_vault_access_policy.developer[0] will be created
  + resource "azurerm_key_vault_access_policy" "developer" {
      + certificate_permissions = [
          + "Get",
          + "List",
        ]
      + id                      = (known after apply)
      + key_permissions         = [
          + "Get",
          + "List",
        ]
      + key_vault_id            = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/apple-shared-infrastructure-sbox/providers/Microsoft.KeyVault/vaults/applesi-sbox"
      + object_id               = "7bde62e7-b39f-487c-95c9-b4c794fdbb96"
      + secret_permissions      = [
          + "Get",
          + "List",
        ]
      + tenant_id               = "531ff96d-0ae9-462a-8d2d-bec7c0b42082"
    }

  # module.vault.azurerm_key_vault_access_policy.managed_identity_access_policy["60ab1441-a8a9-4990-aa30-c94e9f0b047b"] will be created
  + resource "azurerm_key_vault_access_policy" "managed_identity_access_policy" {
      + certificate_permissions = [
          + "Get",
          + "List",
        ]
      + id                      = (known after apply)
      + key_permissions         = [
          + "Get",
          + "List",
        ]
      + key_vault_id            = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/apple-shared-infrastructure-sbox/providers/Microsoft.KeyVault/vaults/applesi-sbox"
      + object_id               = "60ab1441-a8a9-4990-aa30-c94e9f0b047b"
      + secret_permissions      = [
          + "Get",
          + "List",
        ]
      + tenant_id               = "531ff96d-0ae9-462a-8d2d-bec7c0b42082"
    }

  # module.vault.azurerm_key_vault_access_policy.product_team_access_policy will be created
  + resource "azurerm_key_vault_access_policy" "product_team_access_policy" {
      + certificate_permissions = [
          + "List",
          + "Update",
          + "Create",
          + "Import",
          + "Delete",
          + "ManageContacts",
          + "ManageIssuers",
          + "GetIssuers",
          + "ListIssuers",
          + "SetIssuers",
          + "DeleteIssuers",
          + "Recover",
        ]
      + id                      = (known after apply)
      + key_permissions         = [
          + "List",
          + "Update",
          + "Create",
          + "Import",
          + "Delete",
          + "Recover",
        ]
      + key_vault_id            = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/apple-shared-infrastructure-sbox/providers/Microsoft.KeyVault/vaults/applesi-sbox"
      + object_id               = "e7ea2042-4ced-45dd-8ae3-e051c6551789"
      + secret_permissions      = [
          + "List",
          + "Set",
          + "Delete",
          + "Recover",
        ]
      + tenant_id               = "531ff96d-0ae9-462a-8d2d-bec7c0b42082"
    }

  # module.vault.azurerm_monitor_diagnostic_setting.kv-ds will be created
  + resource "azurerm_monitor_diagnostic_setting" "kv-ds" {
      + id                             = (known after apply)
      + log_analytics_destination_type = (known after apply)
      + log_analytics_workspace_id     = "/subscriptions/bf308a5c-0624-4334-8ff8-8dca9fd43783/resourceGroups/oms-automation/providers/Microsoft.OperationalInsights/workspaces/hmcts-sandbox"
      + name                           = "applesi-sbox"
      + target_resource_id             = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/apple-shared-infrastructure-sbox/providers/Microsoft.KeyVault/vaults/applesi-sbox"

      + enabled_log {
          + category = "AuditEvent"
        }
    }

  # module.vault.azurerm_user_assigned_identity.managed_identity[0] will be updated in-place
  ~ resource "azurerm_user_assigned_identity" "managed_identity" {
        id                  = "/subscriptions/a8140a9e-f1b0-481f-a4de-09e2ee23f7ab/resourceGroups/managed-identities-sbox-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/apple-sbox-mi"
        name                = "apple-sbox-mi"
      ~ tags                = {
            "application"         = "core"
            "autoShutdown"        = "true"
            "builtFrom"           = "https://github.com/HMCTS/sds-toffee-shared-infrastructure.git"
            "businessArea"        = "Cross-Cutting"
            "contactSlackChannel" = "#platops-help"
            "environment"         = "sandbox"
          ~ "expiresAfter"        = "2024-03-20" -> "3000-01-01"
            "managedBy"           = "Platform Operations"
            "startupMode"         = "onDemand"
        }
        # (5 unchanged attributes hidden)
    }

Plan: 7 to add, 5 to change, 1 to destroy.

@hannah38 hannah38 marked this pull request as draft April 2, 2024 12:37
@cpareek cpareek closed this Oct 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant