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

does not work in single AZ #166

Open
gecube opened this issue Nov 26, 2024 · 1 comment
Open

does not work in single AZ #166

gecube opened this issue Nov 26, 2024 · 1 comment
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed

Comments

@gecube
Copy link

gecube commented Nov 26, 2024

test case:

provider "aws" {
  region = "eu-west-2"
}


module "networks" {
  source = "git::https://github.com/isovalent/terraform-aws-vpc?ref=v1.10"
  
  name = "dev"
  region = "eu-west-2"
  tags = { "env": "dev" }
  availability_zones = [
    "eu-west-2a"
  ]
  cidr = "172.16.0.0/16"
}

module "talos" {
  source = "git::https://github.com/isovalent/terraform-aws-talos?ref=v0.8.0"

  // Supported Talos versions (and therefore K8s versions) can be found here: https://github.com/siderolabs/talos/releases
  talos_version      = "v1.8.3"
  kubernetes_version = "1.31.2"
  cluster_name       = "talos-cute"
  region             = "eu-west-2"
  tags               = { "env": "dev" }
  vpc_id             = module.networks.id
  pod_cidr           = "100.64.0.0/16"
  service_cidr       = "100.65.0.0/16"
}

hangs on:

815899 --filters Name=tag:type,Values=public --region eu-west-2
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ jq -e '.Subnets[].AvailabilityZone'
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ wc -l
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ xargs
module.talos.null_resource.wait_for_public_subnets (local-exec): + ((  1 < 2  ))
module.talos.null_resource.wait_for_public_subnets (local-exec): + sleep 1
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ aws ec2 describe-subnets --filters Name=vpc-id,Values=vpc-0ac82f7f327815899 --filters Name=tag:type,Values=public --region eu-west-2
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ jq -e '.Subnets[].AvailabilityZone'
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ wc -l
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ xargs
module.talos.null_resource.wait_for_public_subnets (local-exec): + ((  1 < 2  ))
module.talos.null_resource.wait_for_public_subnets (local-exec): + sleep 1
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ aws ec2 describe-subnets --filters Name=vpc-id,Values=vpc-0ac82f7f327815899 --filters Name=tag:type,Values=public --region eu-west-2
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ jq -e '.Subnets[].AvailabilityZone'
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ wc -l
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ xargs
module.talos.null_resource.wait_for_public_subnets (local-exec): + ((  1 < 2  ))
module.talos.null_resource.wait_for_public_subnets (local-exec): + sleep 1
module.talos.null_resource.wait_for_public_subnets: Still creating... [5m0s elapsed]
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ aws ec2 describe-subnets --filters Name=vpc-id,Values=vpc-0ac82f7f327815899 --filters Name=tag:type,Values=public --region eu-west-2
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ jq -e '.Subnets[].AvailabilityZone'
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ wc -l
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ xargs
module.talos.null_resource.wait_for_public_subnets (local-exec): + ((  1 < 2  ))
module.talos.null_resource.wait_for_public_subnets (local-exec): + sleep 1
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ aws ec2 describe-subnets --filters Name=vpc-id,Values=vpc-0ac82f7f327815899 --filters Name=tag:type,Values=public --region eu-west-2
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ jq -e '.Subnets[].AvailabilityZone'
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ wc -l
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ xargs
module.talos.null_resource.wait_for_public_subnets (local-exec): + ((  1 < 2  ))
module.talos.null_resource.wait_for_public_subnets (local-exec): + sleep 1
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ aws ec2 describe-subnets --filters Name=vpc-id,Values=vpc-0ac82f7f327815899 --filters Name=tag:type,Values=public --region eu-west-2
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ jq -e '.Subnets[].AvailabilityZone'
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ wc -l
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ xargs
module.talos.null_resource.wait_for_public_subnets (local-exec): + ((  1 < 2  ))
module.talos.null_resource.wait_for_public_subnets (local-exec): + sleep 1
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ aws ec2 describe-subnets --filters Name=vpc-id,Values=vpc-0ac82f7f327815899 --filters Name=tag:type,Values=public --region eu-west-2
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ jq -e '.Subnets[].AvailabilityZone'
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ wc -l
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ xargs
module.talos.null_resource.wait_for_public_subnets (local-exec): + ((  1 < 2  ))
module.talos.null_resource.wait_for_public_subnets (local-exec): + sleep 1
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ aws ec2 describe-subnets --filters Name=vpc-id,Values=vpc-0ac82f7f327815899 --filters Name=tag:type,Values=public --region eu-west-2
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ jq -e '.Subnets[].AvailabilityZone'
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ wc -l
module.talos.null_resource.wait_for_public_subnets (local-exec): ++ xargs
module.talos.null_resource.wait_for_public_subnets: Still creating... [5m10s elapsed]
^CStopping operation...

till you kill terraform.

@PhilipSchmid PhilipSchmid added the enhancement New feature or request label Dec 5, 2024
@PhilipSchmid
Copy link
Collaborator

Hi @gecube,

Thanks for reporting this!

Currently, that's indeed a limitation that would need to be lifted with a slightly improved logic for scripts/wait-for-public-subnets.sh and the subnet_id assignments for the CP EC2 and worker EC2 instances. I don't think we'll implement that anytime soon, as we don't have this use case. We're still, of course, more than happy to review PRs that implement this support.

Thanks & regards,
Philip

@PhilipSchmid PhilipSchmid added good first issue Good for newcomers help wanted Extra attention is needed labels Dec 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants