use of io.fabric8.openshift.client.internal.OpenShiftOAuthInterceptor in project che-server by eclipse-che.
the class OpenShiftClientFactory method clientForConfig.
private OkHttpClient clientForConfig(Config config) {
OkHttpClient clientHttpClient = getHttpClient().newBuilder().authenticator(Authenticator.NONE).build();
OkHttpClient.Builder builder = clientHttpClient.newBuilder();
builder.interceptors().clear();
return builder.addInterceptor(new OpenShiftOAuthInterceptor(clientHttpClient, OpenShiftConfig.wrap(config))).addInterceptor(new ImpersonatorInterceptor(config)).build();
}
use of io.fabric8.openshift.client.internal.OpenShiftOAuthInterceptor in project devspaces-images by redhat-developer.
the class OpenShiftClientFactory method clientForConfig.
private OkHttpClient clientForConfig(Config config) {
OkHttpClient clientHttpClient = getHttpClient().newBuilder().authenticator(Authenticator.NONE).build();
OkHttpClient.Builder builder = clientHttpClient.newBuilder();
builder.interceptors().clear();
return builder.addInterceptor(new OpenShiftOAuthInterceptor(clientHttpClient, OpenShiftConfig.wrap(config))).addInterceptor(new ImpersonatorInterceptor(config)).build();
}
Aggregations