aws-samples / aws-samples/hardeneks

Not Able to Run On Windows

Open
#24 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
959
Forks
94
PR merge metrics
No merged PRs in 30d

Description

ON Windows, I am able to install hardeneks, but when I run the command I get a 403 for every single kubernetes command.

It looks like the python client we are using is not sending the authorization bearer token alongside the request by default.
If I hardcode this in I see the auth token being passed and everything works. If I remove the api_key and prefix, I don't see it. possibly something that is wrong in my kube config, but on mac and linux it works fine.

```
kubernetes.config.load_kube_config(context=context)
configuration = kubernetes.client.Configuration.get_default_copy()
configuration.debug = True
configuration.api_key = {"authorization": "foobar"}
configuration.api_key_prefix = {"authorization": "bearer"}
kubernetes.client.Configuration.set_default(configuration)
```

I dont see an issue on the python kubernetes client repo that says other users are having this issue so it could possibly be a version issue of windows or the client I am running. I need more assistance to help test on Windows to confirm.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the hardeneks command on Windows with the shown kubernetes.config.load_kube_config and Configuration setup, then compare its requests with macOS or Linux. Investigate whether the kube config or Python Kubernetes client sends the authorization bearer token; done means identifying the Windows-specific cause and verifying a fix or documented resolution across the affected Kubernetes commands.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, kubernetes, python
Domain
authentication, backend, cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.