Class CosBackend.Builder

java.lang.Object
com.hashicorp.cdktf.CosBackend.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<CosBackend>
Enclosing class:
CosBackend

@Stability(Experimental) public static final class CosBackend.Builder extends Object implements software.amazon.jsii.Builder<CosBackend>
(experimental) A fluent builder for CosBackend.
  • Method Details

    • create

      @Stability(Experimental) public static CosBackend.Builder create(software.constructs.Construct scope)
      Parameters:
      scope - This parameter is required.
      Returns:
      a new instance of CosBackend.Builder.
    • bucket

      @Stability(Experimental) public CosBackend.Builder bucket(String bucket)
      (experimental) (Required) The name of the COS bucket.

      You shall manually create it first.

      Parameters:
      bucket - (Required) The name of the COS bucket. This parameter is required.
      Returns:
      this
    • accelerate

      @Stability(Experimental) public CosBackend.Builder accelerate(Boolean accelerate)
      (experimental) (Optional) Whether to enable global Acceleration.

      Defaults to false.

      Parameters:
      accelerate - (Optional) Whether to enable global Acceleration. This parameter is required.
      Returns:
      this
    • acl

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

      Defaults to private.

      Parameters:
      acl - (Optional) Object ACL to be applied to the state file, allows private and public-read. This parameter is required.
      Returns:
      this
    • assumeRole

      @Stability(Experimental) public CosBackend.Builder assumeRole(CosBackendAssumeRole assumeRole)
      (experimental) (Optional) The assume_role block.

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

      Parameters:
      assumeRole - (Optional) The assume_role block. This parameter is required.
      Returns:
      this
    • domain

      @Stability(Experimental) public CosBackend.Builder domain(String domain)
      (experimental) (Optional) The root domain of the API request.

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

      Parameters:
      domain - (Optional) The root domain of the API request. This parameter is required.
      Returns:
      this
    • encrypt

      @Stability(Experimental) public CosBackend.Builder encrypt(Boolean encrypt)
      (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.

      Parameters:
      encrypt - (Optional) Whether to enable server side encryption of the state file. This parameter is required.
      Returns:
      this
    • endpoint

      @Stability(Experimental) public CosBackend.Builder endpoint(String endpoint)
      (experimental) (Optional) The Custom Endpoint for the COS backend.

      It supports the environment variable TENCENTCLOUD_ENDPOINT.

      Parameters:
      endpoint - (Optional) The Custom Endpoint for the COS backend. This parameter is required.
      Returns:
      this
    • key

      @Stability(Experimental) public CosBackend.Builder key(String key)
      (experimental) (Optional) The path for saving the state file in bucket.

      Defaults to terraform.tfstate.

      Parameters:
      key - (Optional) The path for saving the state file in bucket. This parameter is required.
      Returns:
      this
    • prefix

      @Stability(Experimental) public CosBackend.Builder prefix(String prefix)
      (experimental) (Optional) The directory for saving the state file in bucket.

      Default to "env:".

      Parameters:
      prefix - (Optional) The directory for saving the state file in bucket. This parameter is required.
      Returns:
      this
    • region

      @Stability(Experimental) public CosBackend.Builder region(String region)
      (experimental) (Optional) The region of the COS bucket.

      It supports environment variables TENCENTCLOUD_REGION.

      Parameters:
      region - (Optional) The region of the COS bucket. This parameter is required.
      Returns:
      this
    • secretId

      @Stability(Experimental) public CosBackend.Builder secretId(String secretId)
      (experimental) (Optional) Secret id of Tencent Cloud.

      It supports environment variables TENCENTCLOUD_SECRET_ID.

      Parameters:
      secretId - (Optional) Secret id of Tencent Cloud. This parameter is required.
      Returns:
      this
    • secretKey

      @Stability(Experimental) public CosBackend.Builder secretKey(String secretKey)
      (experimental) (Optional) Secret key of Tencent Cloud.

      It supports environment variables TENCENTCLOUD_SECRET_KEY.

      Parameters:
      secretKey - (Optional) Secret key of Tencent Cloud. This parameter is required.
      Returns:
      this
    • securityToken

      @Stability(Experimental) public CosBackend.Builder securityToken(String securityToken)
      (experimental) (Optional) TencentCloud Security Token of temporary access credentials.

      It supports environment variables TENCENTCLOUD_SECURITY_TOKEN.

      Parameters:
      securityToken - (Optional) TencentCloud Security Token of temporary access credentials. This parameter is required.
      Returns:
      this
    • build

      @Stability(Experimental) public CosBackend build()
      Specified by:
      build in interface software.amazon.jsii.Builder<CosBackend>
      Returns:
      a newly built instance of CosBackend.