Skip to main content
The local backend stores state on the local filesystem, locks that state using system APIs, and performs operations locally. Read more about this backend in the Terraform docs: https://developer.hashicorp.com/terraform/language/settings/backends/local

Initializer

import io.cdktn.cdktn.LocalBackendConfig;

LocalBackendConfig.builder()
//  .path(java.lang.String)
//  .workspaceDir(java.lang.String)
    .build();

Properties

NameTypeDescription
pathjava.lang.StringPath where the state file is stored.
workspaceDirjava.lang.String(Optional) The path to non-default workspaces.

pathOptional

public java.lang.String getPath();
  • Type: java.lang.String
  • Default: defaults to terraform.${stackId}.tfstate
Path where the state file is stored.

workspaceDirOptional

public java.lang.String getWorkspaceDir();
  • Type: java.lang.String
(Optional) The path to non-default workspaces.