| --- |
| # ---------------------------------------------------------------------------- |
| # |
| # *** AUTO GENERATED CODE *** Type: MMv1 *** |
| # |
| # ---------------------------------------------------------------------------- |
| # |
| # This file is automatically generated by Magic Modules and manual |
| # changes will be clobbered when the file is regenerated. |
| # |
| # Please read more about how to change this file in |
| # .github/CONTRIBUTING.md. |
| # |
| # ---------------------------------------------------------------------------- |
| subcategory: "Backup and DR" |
| description: |- |
| A Backup and DR Management Server (Also referred as Management Console) |
| --- |
| |
| # google\_backup\_dr\_management\_server |
| |
| A Backup and DR Management Server (Also referred as Management Console) |
| |
| ~> **Warning:** This resource is in beta, and should be used with the terraform-provider-google-beta provider. |
| See [Provider Versions](https://terraform.io/docs/providers/google/guides/provider_versions.html) for more details on beta resources. |
| |
| To get more information about ManagementServer, see: |
| |
| * [API documentation](https://cloud.google.com/backup-disaster-recovery/docs/deployment/deployment-plan) |
| * How-to Guides |
| * [Official Documentation](https://cloud.google.com/backup-disaster-recovery/docs) |
| |
| ## Example Usage - Backup Dr Management Server |
| |
| |
| ```hcl |
| resource "google_compute_network" "default" { |
| provider = google-beta |
| name = "vpc-network" |
| } |
| |
| resource "google_compute_global_address" "private_ip_address" { |
| provider = google-beta |
| name = "vpc-network" |
| address_type = "INTERNAL" |
| purpose = "VPC_PEERING" |
| prefix_length = 20 |
| network = google_compute_network.default.id |
| } |
| |
| resource "google_service_networking_connection" "default" { |
| provider = google-beta |
| network = google_compute_network.default.id |
| service = "servicenetworking.googleapis.com" |
| reserved_peering_ranges = [google_compute_global_address.private_ip_address.name] |
| } |
| |
| resource "google_backup_dr_management_server" "ms-console" { |
| provider = google-beta |
| location = "us-central1" |
| name = "ms-console" |
| type = "BACKUP_RESTORE" |
| networks { |
| network = google_compute_network.default.id |
| peering_mode = "PRIVATE_SERVICE_ACCESS" |
| } |
| depends_on = [ google_service_networking_connection.default ] |
| } |
| ``` |
| |
| ## Argument Reference |
| |
| The following arguments are supported: |
| |
| |
| * `networks` - |
| (Required) |
| Network details to create management server (management console). |
| Structure is [documented below](#nested_networks). |
| |
| * `location` - |
| (Required) |
| The location for the management server (management console) |
| |
| * `name` - |
| (Required) |
| The name of management server (management console) |
| |
| |
| <a name="nested_networks"></a>The `networks` block supports: |
| |
| * `network` - |
| (Required) |
| Network with format `projects/{{project_id}}/global/networks/{{network_id}}` |
| |
| * `peering_mode` - |
| (Optional) |
| Type of Network peeringMode |
| Default value is `PRIVATE_SERVICE_ACCESS`. |
| Possible values are: `PRIVATE_SERVICE_ACCESS`. |
| |
| - - - |
| |
| |
| * `type` - |
| (Optional) |
| The type of management server (management console). |
| Default value is `BACKUP_RESTORE`. |
| Possible values are: `BACKUP_RESTORE`. |
| |
| * `project` - (Optional) The ID of the project in which the resource belongs. |
| If it is not provided, the provider project is used. |
| |
| |
| ## Attributes Reference |
| |
| In addition to the arguments listed above, the following computed attributes are exported: |
| |
| * `id` - an identifier for the resource with format `projects/{{project}}/locations/{{location}}/managementServers/{{name}}` |
| |
| * `oauth2_client_id` - |
| The oauth2ClientId of management console. |
| |
| * `management_uri` - |
| The management console URI |
| Structure is [documented below](#nested_management_uri). |
| |
| |
| <a name="nested_management_uri"></a>The `management_uri` block contains: |
| |
| * `web_ui` - |
| (Output) |
| The management console webUi. |
| |
| * `api` - |
| (Output) |
| The management console api endpoint. |
| |
| ## Timeouts |
| |
| This resource provides the following |
| [Timeouts](https://developer.hashicorp.com/terraform/plugin/sdkv2/resources/retries-and-customizable-timeouts) configuration options: |
| |
| - `create` - Default is 40 minutes. |
| - `delete` - Default is 40 minutes. |
| |
| ## Import |
| |
| |
| ManagementServer can be imported using any of these accepted formats: |
| |
| * `projects/{{project}}/locations/{{location}}/managementServers/{{name}}` |
| * `{{project}}/{{location}}/{{name}}` |
| * `{{location}}/{{name}}` |
| |
| |
| In Terraform v1.5.0 and later, use an [`import` block](https://developer.hashicorp.com/terraform/language/import) to import ManagementServer using one of the formats above. For example: |
| |
| ```tf |
| import { |
| id = "projects/{{project}}/locations/{{location}}/managementServers/{{name}}" |
| to = google_backup_dr_management_server.default |
| } |
| ``` |
| |
| When using the [`terraform import` command](https://developer.hashicorp.com/terraform/cli/commands/import), ManagementServer can be imported using one of the formats above. For example: |
| |
| ``` |
| $ terraform import google_backup_dr_management_server.default projects/{{project}}/locations/{{location}}/managementServers/{{name}} |
| $ terraform import google_backup_dr_management_server.default {{project}}/{{location}}/{{name}} |
| $ terraform import google_backup_dr_management_server.default {{location}}/{{name}} |
| ``` |
| |
| ## User Project Overrides |
| |
| This resource supports [User Project Overrides](https://registry.terraform.io/providers/hashicorp/google/latest/docs/guides/provider_reference#user_project_override). |