Azure / terraform-azurerm-avm-ptn-odaa

AVM Pattern module for Oracle Database @ Azure deployment
MIT License
0 stars 0 forks source link

Oracle Exadata appliance deployment on Azure - Pattern module

This pattern module deploys an Oracle Exadata appliance on Azure, with a virtual network and other supporting resources necessary.

It deploys at a minimum the following resources:

Limitations: This module does not currently handle updates to the Oracle resources, since the underlying resource providers(REST API) do not support Update operations. Hence idempotency is not currently implemented.

[!IMPORTANT] As the overall AVM framework is not GA (generally available) yet - the CI framework and test automation is not fully functional and implemented across all supported languages yet - breaking changes are expected, and additional customer feedback is yet to be gathered and incorporated. Hence, modules MUST NOT be published at version 1.0.0 or higher at this time.

All module MUST be published as a pre-release version (e.g., 0.1.0, 0.1.1, 0.2.0, etc.) until the AVM framework becomes GA.

However, it is important to note that this DOES NOT mean that the modules cannot be consumed and utilized. They CAN be leveraged in all types of environments (dev, test, prod etc.). Consumers can treat them just like any other IaC module and raise issues or feature requests against them as they learn from the usage of the module. Consumers should also read the release notes for each version, if considering updating to a more recent version of a module to see if there are any considerations or breaking changes etc.

Requirements

The following requirements are needed by this module:

Resources

The following resources are used by this module:

Required Inputs

The following input variables are required:

cloud_exadata_infrastructure

Description: Cloud Exadata Infrastructure resources

Type:

map(object({
    name                                 = string
    location                             = string
    zone                                 = string
    compute_count                        = number
    display_name                         = string
    maintenance_window_loadtime_in_weeks = optional(string, 0)
    maintenance_window_preference        = optional(string, "NoPreference")
    maintenance_window_patching_mode     = optional(string, "Rolling")
    shape                                = optional(string, "Exadata.X9M")
    storage_count                        = number
    tags                                 = optional(map(string))
  }))

cloud_exadata_vm_cluster

Description: Cloud Exadata VM Cluster resources

Type:

map(object({
    cluster_name               = string
    display_name               = string
    cloud_exadata_infra_name   = string
    location                   = string
    data_storage_size_in_tbs   = number
    dbnode_storage_size_in_gbs = number
    hostname                   = string
    cpu_core_count             = number
    data_storage_percentage    = number
    memory_size_in_gbs         = number

    ssh_public_keys = list(string)
    nsg_cidrs = optional(set(object({
      source = string
      destination_port_range = optional(object({
        min = string
        max = string
      }), null)
    })))
    license_model                = optional(string, "LicenseIncluded")
    vnet_name                    = string
    client_subnet_name           = string
    backup_subnet_cidr           = string
    gi_version                   = optional(string, "19.0.0.0")
    time_zone                    = string
    is_local_backup_enabled      = optional(bool, true)
    is_sparse_diskgroup_enabled  = optional(bool, true)
    is_diagnostic_events_enabled = optional(bool, false)
    is_health_monitoring_enabled = optional(bool, false)
    is_incident_logs_enabled     = optional(bool, false)
    tags                         = optional(map(string))
  }))

location

Description: Azure region where the resource should be deployed.

Type: string

odaa_vnet_peerings

Description: List of virtual network peerings to be setup

Type:

map(object({
    vnet_source_resource_group      = string
    vnet_destination_resource_group = string
    vnet_source_name                = string
    vnet_destination_name           = string
    }
  ))

resource_group_name

Description: The resource group where the resources will be deployed.

Type: string

Optional Inputs

The following input variables are optional (have default values):

enable_telemetry

Description: This variable controls whether or not telemetry is enabled for the module.
For more information see https://aka.ms/avm/telemetryinfo.
If it is set to false, then no telemetry will be collected.

Type: bool

Default: true

tags

Description: (Optional) Tags of the resource.

Type: map(string)

Default: null

virtual_networks

Description: Virtual Network(s) for hosting Exadata appliances

Type:

map(object({
    address_space = list(string)
    name          = string
    ddos_protection_plan = optional(object({
      enable = bool
      id     = string
    }), null)
    encryption = optional(object({
      enforcement = string
    }), null)
    flow_timeout_in_minutes = optional(number, null)
    resource_group_name     = optional(string, null)
    subnet = optional(set(object({
      delegate_to_oracle = bool
      address_prefixes   = list(string)
      name               = string
      security_group     = optional(string, null)
    })), null)
    diagnostic_settings = optional(map(object({
      name                                     = optional(string, null)
      log_categories                           = optional(set(string), [])
      log_groups                               = optional(set(string), ["allLogs"])
      metric_categories                        = optional(set(string), ["AllMetrics"])
      log_analytics_destination_type           = optional(string, "Dedicated")
      workspace_resource_id                    = optional(string, null)
      storage_account_resource_id              = optional(string, null)
      event_hub_authorization_rule_resource_id = optional(string, null)
      event_hub_name                           = optional(string, null)
      marketplace_partner_resource_id          = optional(string, null)
    })), null)
    role_assignments = optional(map(object({
      role_definition_id_or_name             = string
      principal_id                           = string
      description                            = optional(string, null)
      skip_service_principal_aad_check       = optional(bool, false)
      condition                              = optional(string, null)
      condition_version                      = optional(string, null)
      delegated_managed_identity_resource_id = optional(string, null)
      principal_type                         = optional(string, null)
    })), null)
    lock = optional(object({
      kind = string
      name = optional(string, null)
    }), null)
  }))

Default:

{
  "primaryvnet": {
    "address_space": [
      "10.0.0.0/16"
    ],
    "name": "vnet-odaa",
    "subnet": [
      {
        "address_prefixes": [
          "10.0.0.0/24"
        ],
        "delegate_to_oracle": true,
        "name": "client"
      },
      {
        "address_prefixes": [
          "10.0.1.0/24"
        ],
        "delegate_to_oracle": false,
        "name": "backup"
      }
    ]
  }
}

Outputs

The following outputs are exported:

odaa_infra_resource_ids

Description: Resource IDs of the ODAA Infrastructure resources created.

odaa_vmcluster_resource_ids

Description: Resource IDs of the ODAA VM Cluster resources created.

odaa_vnets_resource_ids

Description: Resource IDs of the Virtual networks created

resource_id

Description: Resource ID for tflint compliance

Modules

The following Modules are called:

odaa_infrastructure

Source: Azure/avm-res-oracledatabase-cloudexadatainfrastructure/azurerm

Version: 0.1.0

odaa_vmcluster

Source: Azure/avm-res-oracledatabase-cloudvmcluster/azurerm

Version: 0.1.0

odaa_vnets

Source: Azure/avm-res-network-virtualnetwork/azurerm

Version: 0.1.4

vnet_peerings

Source: ./modules/vnet_peerings

Version:

Data Collection

The software may collect information about you and your use of the software and send it to Microsoft. Microsoft may use this information to provide services and improve our products and services. You may turn off the telemetry as described in the repository. There are also some features in the software that may enable you and Microsoft to collect data from users of your applications. If you use these features, you must comply with applicable law, including providing appropriate notices to users of your applications together with a copy of Microsoft’s privacy statement. Our privacy statement is located at https://go.microsoft.com/fwlink/?LinkID=824704. You can learn more about data collection and use in the help documentation and our privacy statement. Your use of the software operates as your consent to these practices.