Interface CosBackendConfig

All Superinterfaces:
software.amazon.jsii.JsiiSerializable
All Known Subinterfaces:
DataTerraformRemoteStateCosConfig
All Known Implementing Classes:
CosBackendConfig.Jsii$Proxy, DataTerraformRemoteStateCosConfig.Jsii$Proxy

@Generated(value="jsii-pacmak/1.93.0 (build 1706ca5)", date="2024-01-15T15:38:00.875Z") @Stability(Experimental) public interface CosBackendConfig extends software.amazon.jsii.JsiiSerializable
(experimental) Stores the state as an object in a configurable prefix in a given bucket on Tencent Cloud Object Storage (COS).

This backend supports state locking.

Warning! It is highly recommended that you enable Object Versioning on the COS bucket to allow for state recovery in the case of accidental deletions and human error.

Read more about this backend in the Terraform docs: https://developer.hashicorp.com/terraform/language/settings/backends/cos

  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static final class 
    A builder for CosBackendConfig
    static final class 
    An implementation for CosBackendConfig
  • Method Summary

    Modifier and Type
    Method
    Description
     
    default Boolean
    (experimental) (Optional) Whether to enable global Acceleration.
    default String
    (experimental) (Optional) Object ACL to be applied to the state file, allows private and public-read.
    (experimental) (Optional) The assume_role block.
    (experimental) (Required) The name of the COS bucket.
    default String
    (experimental) (Optional) The root domain of the API request.
    default Boolean
    (experimental) (Optional) Whether to enable server side encryption of the state file.
    default String
    (experimental) (Optional) The Custom Endpoint for the COS backend.
    default String
    (experimental) (Optional) The path for saving the state file in bucket.
    default String
    (experimental) (Optional) The directory for saving the state file in bucket.
    default String
    (experimental) (Optional) The region of the COS bucket.
    default String
    (experimental) (Optional) Secret id of Tencent Cloud.
    default String
    (experimental) (Optional) Secret key of Tencent Cloud.
    default String
    (experimental) (Optional) TencentCloud Security Token of temporary access credentials.

    Methods inherited from interface software.amazon.jsii.JsiiSerializable

    $jsii$toJson
  • Method Details

    • getBucket

      @Stability(Experimental) @NotNull String getBucket()
      (experimental) (Required) The name of the COS bucket.

      You shall manually create it first.

    • getAccelerate

      @Stability(Experimental) @Nullable default Boolean getAccelerate()
      (experimental) (Optional) Whether to enable global Acceleration.

      Defaults to false.

    • getAcl

      @Stability(Experimental) @Nullable default String getAcl()
      (experimental) (Optional) Object ACL to be applied to the state file, allows private and public-read.

      Defaults to private.

    • getAssumeRole

      @Stability(Experimental) @Nullable default CosBackendAssumeRole getAssumeRole()
      (experimental) (Optional) The assume_role block.

      If provided, terraform will attempt to assume this role using the supplied credentials.

    • getDomain

      @Stability(Experimental) @Nullable default String getDomain()
      (experimental) (Optional) The root domain of the API request.

      Defaults to tencentcloudapi.com. It supports the environment variable TENCENTCLOUD_DOMAIN.

    • getEncrypt

      @Stability(Experimental) @Nullable default Boolean getEncrypt()
      (experimental) (Optional) Whether to enable server side encryption of the state file.

      If it is true, COS will use 'AES256' encryption algorithm to encrypt state file.

    • getEndpoint

      @Stability(Experimental) @Nullable default String getEndpoint()
      (experimental) (Optional) The Custom Endpoint for the COS backend.

      It supports the environment variable TENCENTCLOUD_ENDPOINT.

    • getKey

      @Stability(Experimental) @Nullable default String getKey()
      (experimental) (Optional) The path for saving the state file in bucket.

      Defaults to terraform.tfstate.

    • getPrefix

      @Stability(Experimental) @Nullable default String getPrefix()
      (experimental) (Optional) The directory for saving the state file in bucket.

      Default to "env:".

    • getRegion

      @Stability(Experimental) @Nullable default String getRegion()
      (experimental) (Optional) The region of the COS bucket.

      It supports environment variables TENCENTCLOUD_REGION.

    • getSecretId

      @Stability(Experimental) @Nullable default String getSecretId()
      (experimental) (Optional) Secret id of Tencent Cloud.

      It supports environment variables TENCENTCLOUD_SECRET_ID.

    • getSecretKey

      @Stability(Experimental) @Nullable default String getSecretKey()
      (experimental) (Optional) Secret key of Tencent Cloud.

      It supports environment variables TENCENTCLOUD_SECRET_KEY.

    • getSecurityToken

      @Stability(Experimental) @Nullable default String getSecurityToken()
      (experimental) (Optional) TencentCloud Security Token of temporary access credentials.

      It supports environment variables TENCENTCLOUD_SECURITY_TOKEN.

    • builder

      @Stability(Experimental) static CosBackendConfig.Builder builder()
      Returns:
      a CosBackendConfig.Builder of CosBackendConfig