alicloud_realtime_compute_vvp_instance

Provides a Realtime Compute Vvp Instance resource.

For information about Realtime Compute Vvp Instance and how to use it, see What is Vvp Instance.

Example Usage

Basic Usage

variable "name" {
  default = "terraform-example"
}

provider "alicloud" {
  region = "cn-hangzhou"
}

resource "random_integer" "default" {
  min = 10000
  max = 99999
}

data "alicloud_zones" "default" {
  available_resource_creation = "VSwitch"
}

data "alicloud_vpcs" "default" {
  name_regex = "^default-NODELETING$"
}

data "alicloud_vswitches" "default" {
  vpc_id  = data.alicloud_vpcs.default.ids.0
  zone_id = "cn-hangzhou-h"
}

resource "alicloud_oss_bucket" "defaultOSS" {
  bucket = "${var.name}-${random_integer.default.result}"
}

data "alicloud_resource_manager_resource_groups" "default" {
  status = "OK"
}

resource "alicloud_realtime_compute_vvp_instance" "default" {
  storage {
    oss {
      bucket = alicloud_oss_bucket.defaultOSS.bucket
    }
  }

  vvp_instance_name = var.name
  vpc_id            = data.alicloud_vpcs.default.ids.0
  zone_id           = "cn-hangzhou-h"
  vswitch_ids = [
    "${data.alicloud_vswitches.default.ids.0}"
  ]
  payment_type = "PayAsYouGo"
}

Deleting alicloud_realtime_compute_vvp_instance or removing it from your configuration

The alicloud_realtime_compute_vvp_instance resource allows you to manage payment_type = "Subscription" instance, but Terraform cannot destroy it. Deleting the subscription resource or removing it from your configuration will remove it from your state file and management, but will not destroy the Instance. You can resume managing the subscription instance via the AlibabaCloud Console.

Argument Reference

The following arguments are supported:

resource_spec

The resource_spec supports the following:

storage

The storage supports the following:

storage-oss

The oss supports the following:

Attributes Reference

The following attributes are exported:

Timeouts

The timeouts block allows you to specify timeouts for certain actions:

Import

Realtime Compute Vvp Instance can be imported using the id, e.g.

$ terraform import alicloud_realtime_compute_vvp_instance.example <id>