aws-quickstart / quickstart-vmware-tanzu-application-platform

AWS Quick Start for VMware Tanzu Application Platform
https://aws-quickstart.github.io/quickstart-vmware-tanzu-application-platform/
Apache License 2.0
13 stars 15 forks source link

Kubectl download failed #104

Closed spagno closed 1 year ago

spagno commented 1 year ago

Hello, I was trying taskcat with the --no-delete option and I saw that tap wasn't installed. Looking at the logs i get:

I'm trying to setup it in eu-south-1 region.

I'm sure I already setup TAP in this region with the old template not using taskcat

regards

tlindsay42 commented 1 year ago

@satya-dillikar and/or @spagno Are you able to duplicate if you set the region to us-west-2 with the --region parameter on Lines 1380-1381? All of the other awscli s3 cp calls in the user-data script use buckets local to that region, so they shouldn't need to be updated. Also, this hasn't been necessary in other regions in previous testing (including GovCloud).

Alternatively, try updating this to a wget or curl statement to download the file over the internet (example) instead of over a VPC gateway S3 endpoint. My intent with this implementation was to minimize billable outbound internet calls, but the data transfer required for this file is trivial.

If either fixes it, send over a PR.

satya-dillikar commented 1 year ago

@spagno , I was able to change the region in .taskcat.yml and were able to successfully upload and test in us-west and us-east regions.

Try changing the region in .taskcat.yml and let us know your findings as Troy suggested. Thanks Satya

matteowiz commented 1 year ago

Hi,

I'm getting the same problem trying installing tap in eu-south-1 region. How can I fix this? Thanks

matteo

leclaist commented 1 year ago

@matteowiz is the region set to eu-south-1 in your .taskcat.yml file?

tlindsay42 commented 1 year ago

Or are you deploying via the CloudFormation management console link (reference)? Or something else?

satya-dillikar commented 1 year ago

@leclaist ,

Yes, for your local testing, you can update the region as eu-south-1 in your .taskcat file or manually deploy it in the eu-south-1 region.

The fix is to

  1. replace cloud-init.sh: line: aws s3 cp --no-progress "s3://amazon-eks/${AwsKubectlVersion}/bin/linux/$arch/kubectl" ./kubectl with curl -O https://s3.us-west-2.amazonaws.com/amazon-eks/1.24.10/2023-01-30/bin/linux/amd64/kubectl [Note: parameterize correct version and arch]

    and

  2. test in the eu-south-1 region.

HTH Satya

matteowiz commented 1 year ago

@leclaist Yes I'm using the CloudFormation Management Console.

How can I edit this script? Do I have to import all the files into a personal bucket and run from there?

Thanks

matteo

tlindsay42 commented 1 year ago

@matteowiz Minor misunderstanding on our end. You don't need to, but if you want, you can add the eu-south-1 region to one of the tests in the ./.taskcat.yml config file and deploy via taskcat. This tool is primarily intended for maintainers, contributors, and CI/CD though. Thank you for your feedback and confirming your deployment method. @leclaist is working on duplicating the issue. Thanks!

hoegaarden commented 1 year ago

This has been adressed here. We are also running the internal CI against eu-south-1 (amongst other regions) and don't see issues re. the kubectl download anymore. So I think we are good to close this. @tlindsay42