rancher / quickstart

381 stars 338 forks source link

[AWS] Fail to search the Windows Server AMI #224

Open pepesan opened 1 year ago

pepesan commented 1 year ago

Issue: I've tried to use the last version of the rancher quickstart with aws support. And, almost my region, eu-west-3, the script can´t find an AMI with the name "Windows_Server-2019-English-Full-ContainersLatest-*". Output:

╷
│ Error: Your query returned no results. Please change your search criteria and try again.
│ 
│   with data.aws_ami.windows,
│   on data.tf line 32, in data "aws_ami" "windows":
│   32: data "aws_ami" "windows" {
│ 
╵

It seams that kind of AMI isn't more supported in AWS: https://aws.amazon.com/marketplace/pp/prodview-iehgssex6veoi The text says "This version has been removed and is no longer available to new customers." So we need to find another AMI to use in our deployments. As a workaround we can substitute the search, for non Windows deployments, in the rancher/aws/data.tf into the aws_ami windows datasource search change:

    values = ["Windows_Server-2019-English-Full-ContainersLatest-*"]

for

    values = ["Windows_Server-2019-*"]
vatsalparekh commented 1 year ago

+1 Seeing this same issue for over a week now

frank-at-suse commented 1 year ago

Amazon has removed that Windows AMI from their catalog.

CleanShot 2023-08-16 at 08 54 41@2x

Will look into finding another AMI or removing Windows from the quickstart if a replacement can't be found.

gokulyc commented 11 months ago

@frank-at-suse Is the issue fixed, still seeing above error

vatsalparekh commented 11 months ago

@gokulyc changing the image name here to EC2LaunchV2-Windows_Server-2019-English-Full-Base-2023.10.11 solves the issue, but I don't see Windows node added to Rancher. So this would work if you're just going to keep add_windows_node = false

gokulyc commented 11 months ago

I used with add_windows_node = false

It didn't worked, I commented on all the windows terraform code. then it worked.

Currently not using this.

vatsalparekh commented 11 months ago

Changing the image name will work, the error is about the missing AMI

jramscom commented 8 months ago

Any objection to updating the TF to fix the issue here? I can submit a PR if its accepted

TheYarbs commented 5 months ago

Had this issue today. I changed the values = ["Windows_Server-2019-English-Full-ContainersLatest-"] to values = ["Windows_Server-2019-"].

Ami still is fine as "windows"

Carlghayes commented 4 months ago

Has anyone circled back on this issue? I've tried modifying the values, but I still get the error that the ami can't be found.