llhuii / dive-into-k8s

Apache License 2.0
0 stars 0 forks source link

k8s认证方式 #26

Open llhuii opened 1 year ago

llhuii commented 1 year ago

inClusterConfig

# k8s.io/client-go/transport/round_trippers.go
# http header Authorization

    req.Header.Set("Authorization", fmt.Sprintf("Bearer %s", token))

x509 证书

通过证书的CN 作为user, O信息为Group