Added new route to retrieve the host's kubeconfig with the execution's SA token
This commit is contained in:
@@ -174,6 +174,9 @@ func (k *KubernetesService) DeleteNamespace(ctx context.Context, ns string) erro
|
||||
return nil
|
||||
}
|
||||
|
||||
// Returns the string representing the token generated for the serviceAccount
|
||||
// in the namespace identified by the value `ns` with the name sa-`ns`, which is valid for
|
||||
// `duration` seconds
|
||||
func (k *KubernetesService) GenerateToken(ctx context.Context, ns string, duration int) (string, error) {
|
||||
// Define TokenRequest (valid for 1 hour)
|
||||
d := int64(duration)
|
||||
|
||||
Reference in New Issue
Block a user