You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Switch to service account after logging into OpenShift Sandbox
The service account will remain authenticated for longer than 15
minutes.
To try this out:
1. Log into an OpenShift Sandbox cluster using the Login workflow
2. Run `oc whoami`. You should see a reference to `pipeline`, which is the
serviceaccount that's being used
3. The Application Explorer should display you as logged in and work as
expected
Closes#3838
Signed-off-by: David Thompson <davthomp@redhat.com>
constresult=awaitwindow.showInformationMessage('OpenShift Sandbox logs you out after 15 minutes. Would you like to switch to a service account to prevent this?',YES,'No');
849
+
if(result===YES){
850
+
awaitCluster.installPipelineUserContext();
851
+
}
852
+
}
853
+
returnCluster.loginMessage(clusterURL);
854
+
}catch(error){
855
+
thrownewVsCommandError(
856
+
`Failed to login to cluster '${clusterURL}' with '${Filters.filterToken(
857
+
error.message,
858
+
)}'!`,
859
+
'Failed to login to cluster',
860
+
);
861
+
}
862
+
});
855
863
}
856
864
857
865
staticvalidateLoginToken(token: string): boolean{
@@ -878,6 +886,39 @@ export class Cluster extends OpenShiftItem {
0 commit comments