Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add rke provisioner related variables #79

Merged
merged 1 commit into from
Oct 26, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions pkg/templates/distos.go
Original file line number Diff line number Diff line change
@@ -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}}"
}
`
46 changes: 46 additions & 0 deletions pkg/templates/variables.go
Original file line number Diff line number Diff line change
Expand Up @@ -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" {
Expand Down