mirror of https://github.com/rancher/dartboard.git
Adapt main.tf
Signed-off-by: Silvio Moioli <silvio@moioli.net>
This commit is contained in:
parent
a786eb7412
commit
bee86a3100
|
|
@ -3,32 +3,18 @@ locals {
|
||||||
availability_zone = "us-east-1a"
|
availability_zone = "us-east-1a"
|
||||||
secondary_availability_zone = "us-east-1b"
|
secondary_availability_zone = "us-east-1b"
|
||||||
|
|
||||||
bastion_ami = "ami-0abac89b48b8cc3bb" // amazon/suse-sles-15-sp4-byos-v20220621-hvm-ssd-arm64
|
bastion_ami = "ami-0b46b6463b1f19e83" // suse-sles-15-sp4-byos-v20221216-hvm-ssd-arm64-636dec81-77a2-4706-9fc7-6fa1c294d759
|
||||||
|
|
||||||
upstream_instance_type = "t3a.xlarge"
|
upstream_instance_type = "t4g.large"
|
||||||
upstream_ami = "ami-0096528c9fcc1a6a9" // Ubuntu: us-east-1 jammy 22.04 LTS amd64 hvm:ebs-ssd 20221118
|
upstream_ami = "ami-0c6c29c5125214c77" // Ubuntu: us-east-1 jammy 22.04 LTS amd64 hvm:ebs-ssd 20230303
|
||||||
upstream_server_count = 3
|
upstream_server_count = 3
|
||||||
upstream_agent_count = 0
|
upstream_agent_count = 0
|
||||||
upstream_distro_version = "v1.4.3/rke_darwin-amd64 v1.24.10-rancher4-1"
|
upstream_distro_version = "v1.24.10+k3s1"
|
||||||
# alternatives:
|
rancher_chart = "https://releases.rancher.com/server-charts/latest/rancher-2.7.1.tgz"
|
||||||
# upstream_distro_version = "v1.24.6+k3s1"
|
upstream_san = "upstream.local.gd"
|
||||||
# upstream_distro_version = "v1.24.8+rke2r1"
|
upstream_kubernetes_api_port = 6443
|
||||||
rancher_chart = "https://releases.rancher.com/server-charts/latest/rancher-2.7.0.tgz"
|
|
||||||
upstream_san = "upstream.local.gd"
|
|
||||||
upstream_kubernetes_api_port = 6443
|
|
||||||
|
|
||||||
downstream_instance_type = "t3a.xlarge"
|
project_name = "moio"
|
||||||
downstream_ami = "ami-0096528c9fcc1a6a9" // Ubuntu: us-east-1 jammy 22.04 LTS amd64 hvm:ebs-ssd 20221118
|
|
||||||
downstream_server_count = 1
|
|
||||||
downstream_agent_count = 1
|
|
||||||
downstream_distro_version = "v1.24.6+k3s1"
|
|
||||||
# alternatives:
|
|
||||||
# downstream_distro_version = "v1.24.8+rke2r1"
|
|
||||||
# downstream_distro_version = "v1.4.3/rke_darwin-amd64 v1.24.10-rancher4-1"
|
|
||||||
downstream_san = "downstream.local.gd"
|
|
||||||
downstream_kubernetes_api_port = 6444
|
|
||||||
|
|
||||||
project_name = "moio"
|
|
||||||
ssh_private_key_path = "~/.ssh/id_ed25519"
|
ssh_private_key_path = "~/.ssh/id_ed25519"
|
||||||
ssh_public_key_path = "~/.ssh/id_ed25519.pub"
|
ssh_public_key_path = "~/.ssh/id_ed25519.pub"
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -56,10 +56,7 @@ module "bastion" {
|
||||||
}
|
}
|
||||||
|
|
||||||
module "upstream_cluster" {
|
module "upstream_cluster" {
|
||||||
source = "./aws_rke"
|
source = "./aws_k3s"
|
||||||
# alternatives:
|
|
||||||
# source = "./aws_k3s"
|
|
||||||
# source = "./aws_rke2"
|
|
||||||
ami = local.upstream_ami
|
ami = local.upstream_ami
|
||||||
instance_type = local.upstream_instance_type
|
instance_type = local.upstream_instance_type
|
||||||
availability_zone = local.availability_zone
|
availability_zone = local.availability_zone
|
||||||
|
|
@ -94,26 +91,3 @@ module "rancher" {
|
||||||
private_name = module.upstream_cluster.first_server_private_name
|
private_name = module.upstream_cluster.first_server_private_name
|
||||||
chart = local.rancher_chart
|
chart = local.rancher_chart
|
||||||
}
|
}
|
||||||
|
|
||||||
module "downstream_cluster" {
|
|
||||||
source = "./aws_k3s"
|
|
||||||
# alternatives:
|
|
||||||
# source = "./aws_rke"
|
|
||||||
# source = "./aws_rke2"
|
|
||||||
ami = local.downstream_ami
|
|
||||||
instance_type = local.downstream_instance_type
|
|
||||||
availability_zone = local.availability_zone
|
|
||||||
project_name = local.project_name
|
|
||||||
name = "downstream"
|
|
||||||
server_count = local.downstream_server_count
|
|
||||||
agent_count = local.downstream_agent_count
|
|
||||||
ssh_key_name = module.aws_shared.key_name
|
|
||||||
ssh_private_key_path = local.ssh_private_key_path
|
|
||||||
ssh_bastion_host = module.bastion.public_name
|
|
||||||
subnet_id = module.aws_network.private_subnet_id
|
|
||||||
vpc_security_group_id = module.aws_network.private_security_group_id
|
|
||||||
kubernetes_api_port = local.downstream_kubernetes_api_port
|
|
||||||
distro_version = local.downstream_distro_version
|
|
||||||
sans = [local.downstream_san]
|
|
||||||
secondary_subnet_id = module.aws_network.secondary_private_subnet_id
|
|
||||||
}
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue