Skip to content

Token Based Cluster Context Not Working #819

@kmadel

Description

@kmadel

What happened?

Uploading the following Kube Config results in this error:

E0315 13:56:23.962506       1 authentication.go:63] "Unable to authenticate the request" err="verifying certificate SN=4792605077399134197, SKID=, AKID=9B:3D:E7:D3:5D:64:7F:70:81:AF:C8:F0:6D:BA:CA:CB:AF:24:B0:D2 failed: x509: certificate signed by unknown authority (possibly because of \"crypto/rsa: verification error\" while trying to verify candidate authority certificate \"kubernetes\")"

Config yaml:

apiVersion: v1
kind: Config
clusters:
- cluster:
    server: https://xxxxxxxxxxxx/kubernetes/project/demos/virtualcluster/xxxx
    insecure-skip-tls-verify: true
  name: loft
contexts:
- context:
    cluster: loft
    user: loft
    
  name: loft
current-context: loft
users:
- name: loft
  user:
    token: K*************************************************7

What did you expect to happen?

Based on this merged PR, I would expect it to work with just a user.token: #527

How can we reproduce it (as minimally and precisely as possible)?

Install vCluster Platform: https://www.vcluster.com/docs/platform/install/quick-start-guide
Then create a vCluster with the Platform, export the KubeConfig and add it to Karpor.

Anything else we need to know?

No response

Karpor version

kusionstack/karpor:v0.6.3

OS version

Details
# On Linux:
$ cat /etc/os-release
# paste output here
$ uname -a
# paste output here

# On Windows:
C:\> wmic os get Caption, Version, BuildNumber, OSArchitecture
# paste output here

Install tools

Details

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions