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

Antctl doesn't work on EKS clusters #4140

Closed
luolanzone opened this issue Aug 19, 2022 · 1 comment
Closed

Antctl doesn't work on EKS clusters #4140

luolanzone opened this issue Aug 19, 2022 · 1 comment
Labels
kind/bug Categorizes issue or PR as related to a bug.

Comments

@luolanzone
Copy link
Contributor

luolanzone commented Aug 19, 2022

Describe the bug
I tried a few antctl commands on a EKS cluster, it seems it doesn't work as we expected and get below errors:

Error: failed to create rest client: exec plugin: invalid apiVersion "client.authentication.k8s.io/v1alpha1"

Here are a few commands I tried, there should be a problem to initialize the rest client correctly due to unexpected API version.

$antctl version
antctlVersion: v1.8.0
Error: failed to create rest client: exec plugin: invalid apiVersion "client.authentication.k8s.io/v1alpha1"
...
$antctl get networkpolicy
Error: failed to create rest client: exec plugin: invalid apiVersion "client.authentication.k8s.io/v1alpha1"

To Reproduce
Run antctl version with a EKS cluster kubeconfig file.

Expected
Antctl should work correctly on EKS clusters.

Actual behavior
Antctl doesn't work on EKS clusters.

Versions:
The version I tried is v1.8.0
But this issue probably also exists on early version.

Additional context

@luolanzone luolanzone added the kind/bug Categorizes issue or PR as related to a bug. label Aug 19, 2022
@luolanzone
Copy link
Contributor Author

It turns out that 'client.authentication.k8s.io/v1alpha1' is deprecated but it's still used by old aws-cli. User need to make sure aws-cli version has this fix: aws/aws-cli#6476.
I followed this guide https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html to deploy latest v2 aws-cli and regenerated the kubeconfig file via aws eks --region $region update-kubeconfig --name $cluster-name --kubeconfig $file-name. Antclt works file with new generated kubeconfig file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug.
Projects
None yet
Development

No branches or pull requests

1 participant