Skip to content

Latest commit

 

History

History
47 lines (35 loc) · 1.38 KB

File metadata and controls

47 lines (35 loc) · 1.38 KB
title `glab opentofu init`
stage Create
group Code Review
info To determine the technical writer assigned to the Stage/Group associated with this page, see <https://handbook.gitlab.com/handbook/product/ux/technical-writing/#assignments>

Initialize OpenTofu or Terraform.

glab opentofu init <state> [flags]

Examples

# Initialize state with name production in working directory
glab opentofu init production

# Initialize state with name production in infra/ directory
glab opentofu init production -d infra/

# Initialize state with name production with Terraform
glab opentofu init production -b terraform

# Initialize state with name production with reconfiguring state
glab opentofu init production -- -reconfigure

Options

  -b, --binary string      Name or path of the OpenTofu or Terraform binary to use for the initialization. (default "tofu")
  -d, --directory string   Directory of the OpenTofu or Terraform project to initialize. (default ".")

Options inherited from parent commands

  -h, --help              Show help for this command.
  -R, --repo OWNER/REPO   Select another repository. Can use either OWNER/REPO or `GROUP/NAMESPACE/REPO` format. Also accepts full URL or Git URL.