diff --git a/pkg/templates/distos.go b/pkg/templates/distos.go new file mode 100644 index 0000000..ae1e6e6 --- /dev/null +++ b/pkg/templates/distos.go @@ -0,0 +1,23 @@ +package templates + +var DistVariablesRKE = ` +data "aws_ami" "distro" { + most_recent = true + + filter { + name = "name" + values = ["{{.NodeOS}}"] + } + + filter { + name = "virtualization-type" + values = ["hvm"] + } + + owners = ["{{.AmiOwner}}"] +} + +variable "ssh_user" { + default = "{{.User}}" +} +` diff --git a/pkg/templates/variables.go b/pkg/templates/variables.go index 4d2255a..5433e71 100644 --- a/pkg/templates/variables.go +++ b/pkg/templates/variables.go @@ -14,6 +14,52 @@ package templates +var VariablesRKE = ` +variable "cluster_name" { + default = "{{.ClusterName}}" + type = "string" + description = "The name of your EKS Cluster" +} + +variable "aws_region" { + default = "{{.AWSRegion}}" + # availabe regions are: + # us-east-1 (Virginia) + # us-west-2 (Oregon) + # eu-west-1 (Irland) + type = "string" + description = "The AWS Region to deploy EKS" +} + +variable "rke_node_instance_type" { + default = "{{.RKENodeInstanceType}}" + type = "string" + description = "Worker Node EC2 instance type" +} + +variable "node_count" { + default = {{.NodeCount}} + type = "string" + description = "Autoscaling Desired node capacity" +} +variable "cloud_provider" { + default = "{{.CloudProvider}}" + type = "string" + description = "cloud provider for rke cluster" +} + +variable "AWS_ACCESS_KEY_ID" { + description = "AWS Access Key" +} + +variable "AWS_SECRET_ACCESS_KEY" { + description = "AWS Secret Key" +} + +variable "AWS_DEFAULT_REGION" { + description = "AWS Region" +} +` var VariablesEKS = ` # Variables Configuration variable "cluster-name" {