diff --git a/examples/skel/provider.tf b/examples/skel/provider.tf new file mode 100644 index 0000000..9a26d39 --- /dev/null +++ b/examples/skel/provider.tf @@ -0,0 +1,27 @@ +provider "aws" { + region = var.aws-region + default_tags { + tags = { + Environment = var.environment + Project = var.project + Application = var.application + TerraformMode = "managed" + BuildDate = time_static.current_time.rfc3339 + TerraformDir = "${reverse(split("/", path.cwd))[1]}/${reverse(split("/", path.cwd))[0]}" + } + } +} + +resource "time_static" "current_time" {} + +terraform { + required_version = ">= 1.3" + required_providers { + aws = { + source = "hashicorp/aws" + version = ">= 5.0" + } + } +} + + diff --git a/examples/skel/terraform.tfvars b/examples/skel/terraform.tfvars new file mode 100644 index 0000000..ab01a90 --- /dev/null +++ b/examples/skel/terraform.tfvars @@ -0,0 +1,5 @@ +aws-region = "ap-east-1" +customer-name = "CX" +environment = "prod" +project = "SupportTools" +application = "Undefined" diff --git a/examples/skel/variables.tf b/examples/skel/variables.tf new file mode 100644 index 0000000..9233cee --- /dev/null +++ b/examples/skel/variables.tf @@ -0,0 +1,5 @@ +variable "aws-region" {} +variable "customer-name" {} +variable "environment" {} +variable "project" {} +variable "application" {}