1. Packages
  2. AWS Classic
  3. API Docs
  4. backup
  5. getVault

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.44.0 published on Monday, Jul 8, 2024 by Pulumi

aws.backup.getVault

Explore with Pulumi AI

aws logo

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.44.0 published on Monday, Jul 8, 2024 by Pulumi

    Use this data source to get information on an existing backup vault.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = aws.backup.getVault({
        name: "example_backup_vault",
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.backup.get_vault(name="example_backup_vault")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/backup"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := backup.LookupVault(ctx, &backup.LookupVaultArgs{
    			Name: "example_backup_vault",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Aws.Backup.GetVault.Invoke(new()
        {
            Name = "example_backup_vault",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.backup.BackupFunctions;
    import com.pulumi.aws.backup.inputs.GetVaultArgs;
    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) {
            final var example = BackupFunctions.getVault(GetVaultArgs.builder()
                .name("example_backup_vault")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          Function: aws:backup:getVault
          Arguments:
            name: example_backup_vault
    

    Using getVault

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getVault(args: GetVaultArgs, opts?: InvokeOptions): Promise<GetVaultResult>
    function getVaultOutput(args: GetVaultOutputArgs, opts?: InvokeOptions): Output<GetVaultResult>
    def get_vault(name: Optional[str] = None,
                  tags: Optional[Mapping[str, str]] = None,
                  opts: Optional[InvokeOptions] = None) -> GetVaultResult
    def get_vault_output(name: Optional[pulumi.Input[str]] = None,
                  tags: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
                  opts: Optional[InvokeOptions] = None) -> Output[GetVaultResult]
    func LookupVault(ctx *Context, args *LookupVaultArgs, opts ...InvokeOption) (*LookupVaultResult, error)
    func LookupVaultOutput(ctx *Context, args *LookupVaultOutputArgs, opts ...InvokeOption) LookupVaultResultOutput

    > Note: This function is named LookupVault in the Go SDK.

    public static class GetVault 
    {
        public static Task<GetVaultResult> InvokeAsync(GetVaultArgs args, InvokeOptions? opts = null)
        public static Output<GetVaultResult> Invoke(GetVaultInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetVaultResult> getVault(GetVaultArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: aws:backup/getVault:getVault
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Name string
    Name of the backup vault.
    Tags Dictionary<string, string>
    Metadata that you can assign to help organize the resources that you create.
    Name string
    Name of the backup vault.
    Tags map[string]string
    Metadata that you can assign to help organize the resources that you create.
    name String
    Name of the backup vault.
    tags Map<String,String>
    Metadata that you can assign to help organize the resources that you create.
    name string
    Name of the backup vault.
    tags {[key: string]: string}
    Metadata that you can assign to help organize the resources that you create.
    name str
    Name of the backup vault.
    tags Mapping[str, str]
    Metadata that you can assign to help organize the resources that you create.
    name String
    Name of the backup vault.
    tags Map<String>
    Metadata that you can assign to help organize the resources that you create.

    getVault Result

    The following output properties are available:

    Arn string
    ARN of the vault.
    Id string
    The provider-assigned unique ID for this managed resource.
    KmsKeyArn string
    Server-side encryption key that is used to protect your backups.
    Name string
    RecoveryPoints int
    Number of recovery points that are stored in a backup vault.
    Tags Dictionary<string, string>
    Metadata that you can assign to help organize the resources that you create.
    Arn string
    ARN of the vault.
    Id string
    The provider-assigned unique ID for this managed resource.
    KmsKeyArn string
    Server-side encryption key that is used to protect your backups.
    Name string
    RecoveryPoints int
    Number of recovery points that are stored in a backup vault.
    Tags map[string]string
    Metadata that you can assign to help organize the resources that you create.
    arn String
    ARN of the vault.
    id String
    The provider-assigned unique ID for this managed resource.
    kmsKeyArn String
    Server-side encryption key that is used to protect your backups.
    name String
    recoveryPoints Integer
    Number of recovery points that are stored in a backup vault.
    tags Map<String,String>
    Metadata that you can assign to help organize the resources that you create.
    arn string
    ARN of the vault.
    id string
    The provider-assigned unique ID for this managed resource.
    kmsKeyArn string
    Server-side encryption key that is used to protect your backups.
    name string
    recoveryPoints number
    Number of recovery points that are stored in a backup vault.
    tags {[key: string]: string}
    Metadata that you can assign to help organize the resources that you create.
    arn str
    ARN of the vault.
    id str
    The provider-assigned unique ID for this managed resource.
    kms_key_arn str
    Server-side encryption key that is used to protect your backups.
    name str
    recovery_points int
    Number of recovery points that are stored in a backup vault.
    tags Mapping[str, str]
    Metadata that you can assign to help organize the resources that you create.
    arn String
    ARN of the vault.
    id String
    The provider-assigned unique ID for this managed resource.
    kmsKeyArn String
    Server-side encryption key that is used to protect your backups.
    name String
    recoveryPoints Number
    Number of recovery points that are stored in a backup vault.
    tags Map<String>
    Metadata that you can assign to help organize the resources that you create.

    Package Details

    Repository
    AWS Classic pulumi/pulumi-aws
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the aws Terraform Provider.
    aws logo

    Try AWS Native preview for resources not in the classic version.

    AWS Classic v6.44.0 published on Monday, Jul 8, 2024 by Pulumi