We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 7b21c7e + 69d615d commit ccf10c6Copy full SHA for ccf10c6
node-client/src/config.ts
@@ -160,6 +160,9 @@ export class KubeConfig {
160
}
161
162
if (token) {
163
+ if (!opts.headers) {
164
+ opts.headers = [];
165
+ }
166
opts.headers['Authorization'] = token;
167
168
@@ -239,6 +242,9 @@ export class Config {
239
242
k8sApi.setDefaultAuthentication({
240
243
'applyToRequest': (opts) => {
241
244
opts.ca = caCert;
245
246
247
248
opts.headers['Authorization'] = 'Bearer ' + token;
249
250
});
0 commit comments