alicloud_amqp_static_account

更新时间:

Provides a Amqp Static Account resource.

For information about Amqp Static Account and how to use it, see What is Static Account.

-> NOTE: Available since v1.195.0.

Example Usage

Basic Usage


provider "alicloud" {
  region = "cn-shanghai"
}
variable "access_key" {
  default = "access_key"
}
variable "secret_key" {
  default = "secret_key"
}
resource "alicloud_amqp_instance" "default" {
  instance_type  = "enterprise"
  max_tps        = 3000
  queue_capacity = 200
  storage_size   = 700
  support_eip    = false
  max_eip_tps    = 128
  payment_type   = "Subscription"
  period         = 1
}
resource "alicloud_amqp_static_account" "default" {
  instance_id = alicloud_amqp_instance.default.id
  access_key  = var.access_key
  secret_key  = var.secret_key
}

Argument Reference

The following arguments are supported:

  • instance_id - (Required, ForceNew) Amqp instance ID.
  • access_key - (Required, ForceNew) Access key.
  • secret_key - (Required, ForceNew) Secret key.

Attributes Reference

The following attributes are exported:

  • id - The resource ID in terraform of Static Account. It formats as <instance_id>:<access_key>.
  • user_name - The static username.
  • password - The static password.
  • master_uid - The ID of the user's primary account.
  • create_time - The timestamp that indicates when the pair of static username and password was created.

Timeouts

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

  • create - (Defaults to 5 mins) Used when create the Static Account.
  • delete - (Defaults to 5 mins) Used when delete the Static Account.

Import

Amqp Static Account can be imported using the id, e.g.

$terraform import alicloud_amqp_static_account.example <instance_id>:<access_key>