local_file

Generates a local file with the given content.

Example Usage

resource "local_file" "foo" {
    content     = "foo!"
    filename = "${path.module}/foo.bar"
}

Argument Reference

The following arguments are supported:

  • content - (Required) The content of file to create.

  • filename - (Required) The path of the file to create.

Any required parent directories will be created automatically, and any existing file with the given name will be overwritten.

© 2018 HashiCorp
Licensed under the MPL 2.0 License.
https://www.terraform.io/docs/providers/local/r/file.html