Prechádzať zdrojové kódy

allowing readonly k8s access (#4636)

Stefan McShane 2 rokov pred
rodič
commit
27359a7fdb
1 zmenil súbory, kde vykonal 1 pridanie a 1 odobranie
  1. 1 1
      api/server/router/cluster.go

+ 1 - 1
api/server/router/cluster.go

@@ -979,7 +979,7 @@ func getClusterRoutes(
 		// GET /api/projects/{project_id}/clusters/{cluster_id}/kubeconfig -> cluster.NewGetTemporaryKubeconfigHandler
 		// GET /api/projects/{project_id}/clusters/{cluster_id}/kubeconfig -> cluster.NewGetTemporaryKubeconfigHandler
 		getTemporaryKubeconfigEndpoint := factory.NewAPIEndpoint(
 		getTemporaryKubeconfigEndpoint := factory.NewAPIEndpoint(
 			&types.APIRequestMetadata{
 			&types.APIRequestMetadata{
-				Verb:   types.APIVerbUpdate, // we do not want users with no-write access to be able to use this
+				Verb:   types.APIVerbGet,
 				Method: types.HTTPVerbGet,
 				Method: types.HTTPVerbGet,
 				Path: &types.Path{
 				Path: &types.Path{
 					Parent:       basePath,
 					Parent:       basePath,