alicloud.hbr.Vault
Explore with Pulumi AI
Provides a HBR Backup vault resource.
For information about HBR Backup vault and how to use it, see What is Backup vault.
NOTE: Available since v1.129.0.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
import * as random from "@pulumi/random";
const _default = new random.index.Integer("default", {
min: 10000,
max: 99999,
});
const example = new alicloud.hbr.Vault("example", {vaultName: `example_value_${_default.result}`});
import pulumi
import pulumi_alicloud as alicloud
import pulumi_random as random
default = random.index.Integer("default",
min=10000,
max=99999)
example = alicloud.hbr.Vault("example", vault_name=f"example_value_{default['result']}")
package main
import (
"fmt"
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/hbr"
"github.com/pulumi/pulumi-random/sdk/v4/go/random"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := random.NewInteger(ctx, "default", &random.IntegerArgs{
Min: 10000,
Max: 99999,
})
if err != nil {
return err
}
_, err = hbr.NewVault(ctx, "example", &hbr.VaultArgs{
VaultName: pulumi.Sprintf("example_value_%v", _default.Result),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
using Random = Pulumi.Random;
return await Deployment.RunAsync(() =>
{
var @default = new Random.Index.Integer("default", new()
{
Min = 10000,
Max = 99999,
});
var example = new AliCloud.Hbr.Vault("example", new()
{
VaultName = $"example_value_{@default.Result}",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.random.integer;
import com.pulumi.random.IntegerArgs;
import com.pulumi.alicloud.hbr.Vault;
import com.pulumi.alicloud.hbr.VaultArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var default_ = new Integer("default", IntegerArgs.builder()
.min(10000)
.max(99999)
.build());
var example = new Vault("example", VaultArgs.builder()
.vaultName(String.format("example_value_%s", default_.result()))
.build());
}
}
resources:
default:
type: random:integer
properties:
min: 10000
max: 99999
example:
type: alicloud:hbr:Vault
properties:
vaultName: example_value_${default.result}
Create Vault Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Vault(name: string, args: VaultArgs, opts?: CustomResourceOptions);
@overload
def Vault(resource_name: str,
args: VaultArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Vault(resource_name: str,
opts: Optional[ResourceOptions] = None,
vault_name: Optional[str] = None,
description: Optional[str] = None,
encrypt_type: Optional[str] = None,
kms_key_id: Optional[str] = None,
vault_storage_class: Optional[str] = None,
vault_type: Optional[str] = None)
func NewVault(ctx *Context, name string, args VaultArgs, opts ...ResourceOption) (*Vault, error)
public Vault(string name, VaultArgs args, CustomResourceOptions? opts = null)
type: alicloud:hbr:Vault
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args VaultArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args VaultArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args VaultArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args VaultArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args VaultArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var vaultResource = new AliCloud.Hbr.Vault("vaultResource", new()
{
VaultName = "string",
Description = "string",
EncryptType = "string",
KmsKeyId = "string",
VaultStorageClass = "string",
VaultType = "string",
});
example, err := hbr.NewVault(ctx, "vaultResource", &hbr.VaultArgs{
VaultName: pulumi.String("string"),
Description: pulumi.String("string"),
EncryptType: pulumi.String("string"),
KmsKeyId: pulumi.String("string"),
VaultStorageClass: pulumi.String("string"),
VaultType: pulumi.String("string"),
})
var vaultResource = new Vault("vaultResource", VaultArgs.builder()
.vaultName("string")
.description("string")
.encryptType("string")
.kmsKeyId("string")
.vaultStorageClass("string")
.vaultType("string")
.build());
vault_resource = alicloud.hbr.Vault("vaultResource",
vault_name="string",
description="string",
encrypt_type="string",
kms_key_id="string",
vault_storage_class="string",
vault_type="string")
const vaultResource = new alicloud.hbr.Vault("vaultResource", {
vaultName: "string",
description: "string",
encryptType: "string",
kmsKeyId: "string",
vaultStorageClass: "string",
vaultType: "string",
});
type: alicloud:hbr:Vault
properties:
description: string
encryptType: string
kmsKeyId: string
vaultName: string
vaultStorageClass: string
vaultType: string
Vault Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Vault resource accepts the following input properties:
- Vault
Name string - The name of Vault.
- Description string
- The description of Vault. Defaults to an empty string.
- Encrypt
Type string - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- Kms
Key stringId - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - Vault
Storage stringClass - The storage class of Vault. Valid values:
STANDARD
. - Vault
Type string - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
- Vault
Name string - The name of Vault.
- Description string
- The description of Vault. Defaults to an empty string.
- Encrypt
Type string - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- Kms
Key stringId - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - Vault
Storage stringClass - The storage class of Vault. Valid values:
STANDARD
. - Vault
Type string - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
- vault
Name String - The name of Vault.
- description String
- The description of Vault. Defaults to an empty string.
- encrypt
Type String - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- kms
Key StringId - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - vault
Storage StringClass - The storage class of Vault. Valid values:
STANDARD
. - vault
Type String - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
- vault
Name string - The name of Vault.
- description string
- The description of Vault. Defaults to an empty string.
- encrypt
Type string - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- kms
Key stringId - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - vault
Storage stringClass - The storage class of Vault. Valid values:
STANDARD
. - vault
Type string - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
- vault_
name str - The name of Vault.
- description str
- The description of Vault. Defaults to an empty string.
- encrypt_
type str - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- kms_
key_ strid - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - vault_
storage_ strclass - The storage class of Vault. Valid values:
STANDARD
. - vault_
type str - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
- vault
Name String - The name of Vault.
- description String
- The description of Vault. Defaults to an empty string.
- encrypt
Type String - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- kms
Key StringId - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - vault
Storage StringClass - The storage class of Vault. Valid values:
STANDARD
. - vault
Type String - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
Outputs
All input properties are implicitly available as output properties. Additionally, the Vault resource produces the following output properties:
Look up Existing Vault Resource
Get an existing Vault resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: VaultState, opts?: CustomResourceOptions): Vault
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
description: Optional[str] = None,
encrypt_type: Optional[str] = None,
kms_key_id: Optional[str] = None,
status: Optional[str] = None,
vault_name: Optional[str] = None,
vault_storage_class: Optional[str] = None,
vault_type: Optional[str] = None) -> Vault
func GetVault(ctx *Context, name string, id IDInput, state *VaultState, opts ...ResourceOption) (*Vault, error)
public static Vault Get(string name, Input<string> id, VaultState? state, CustomResourceOptions? opts = null)
public static Vault get(String name, Output<String> id, VaultState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Description string
- The description of Vault. Defaults to an empty string.
- Encrypt
Type string - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- Kms
Key stringId - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - Status string
- The status of the Vault.
- Vault
Name string - The name of Vault.
- Vault
Storage stringClass - The storage class of Vault. Valid values:
STANDARD
. - Vault
Type string - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
- Description string
- The description of Vault. Defaults to an empty string.
- Encrypt
Type string - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- Kms
Key stringId - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - Status string
- The status of the Vault.
- Vault
Name string - The name of Vault.
- Vault
Storage stringClass - The storage class of Vault. Valid values:
STANDARD
. - Vault
Type string - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
- description String
- The description of Vault. Defaults to an empty string.
- encrypt
Type String - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- kms
Key StringId - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - status String
- The status of the Vault.
- vault
Name String - The name of Vault.
- vault
Storage StringClass - The storage class of Vault. Valid values:
STANDARD
. - vault
Type String - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
- description string
- The description of Vault. Defaults to an empty string.
- encrypt
Type string - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- kms
Key stringId - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - status string
- The status of the Vault.
- vault
Name string - The name of Vault.
- vault
Storage stringClass - The storage class of Vault. Valid values:
STANDARD
. - vault
Type string - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
- description str
- The description of Vault. Defaults to an empty string.
- encrypt_
type str - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- kms_
key_ strid - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - status str
- The status of the Vault.
- vault_
name str - The name of Vault.
- vault_
storage_ strclass - The storage class of Vault. Valid values:
STANDARD
. - vault_
type str - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
- description String
- The description of Vault. Defaults to an empty string.
- encrypt
Type String - Source Encryption Type,It is valid only when vault_type is
STANDARD
orOTS_BACKUP
. Default value:HBR_PRIVATE
. Valid values:HBR_PRIVATE
: HBR is fully hosted, uses the backup service's own encryption method.KMS
: Use Alibaba Cloud Kms to encryption.
- kms
Key StringId - The key id or alias name of Alibaba Cloud Kms. It is required and valid only when encrypt_type is
KMS
. - status String
- The status of the Vault.
- vault
Name String - The name of Vault.
- vault
Storage StringClass - The storage class of Vault. Valid values:
STANDARD
. - vault
Type String - The type of Vault. Valid values:
STANDARD
,OTS_BACKUP
.
Import
HBR Vault can be imported using the id, e.g.
$ pulumi import alicloud:hbr/vault:Vault example <id>
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.