trying a fix for self-hosted runners
This commit is contained in:
@ -15,7 +15,6 @@ const querystring = require("querystring");
|
|||||||
const az_login = require("./main");
|
const az_login = require("./main");
|
||||||
const path = require("path");
|
const path = require("path");
|
||||||
const child_process_1 = require("child_process");
|
const child_process_1 = require("child_process");
|
||||||
const fs = require("fs");
|
|
||||||
function getAzureAccessToken(servicePrincipalId, servicePrincipalKey, tenantId, authorityUrl, managementEndpointUrl) {
|
function getAzureAccessToken(servicePrincipalId, servicePrincipalKey, tenantId, authorityUrl, managementEndpointUrl) {
|
||||||
return __awaiter(this, void 0, void 0, function* () {
|
return __awaiter(this, void 0, void 0, function* () {
|
||||||
if (!servicePrincipalId || !servicePrincipalKey || !tenantId || !authorityUrl) {
|
if (!servicePrincipalId || !servicePrincipalKey || !tenantId || !authorityUrl) {
|
||||||
@ -94,7 +93,7 @@ function getArcKubeconfig() {
|
|||||||
}
|
}
|
||||||
console.log('Waiting for 2 minutes for kubeconfig to be merged....');
|
console.log('Waiting for 2 minutes for kubeconfig to be merged....');
|
||||||
yield sleep(120000); //sleeping for 2 minutes to allow kubeconfig to be merged
|
yield sleep(120000); //sleeping for 2 minutes to allow kubeconfig to be merged
|
||||||
fs.chmodSync(kubeconfigPath, '600');
|
//fs.chmodSync(kubeconfigPath, '600');
|
||||||
core.exportVariable('KUBECONFIG', kubeconfigPath);
|
core.exportVariable('KUBECONFIG', kubeconfigPath);
|
||||||
console.log('KUBECONFIG environment variable is set');
|
console.log('KUBECONFIG environment variable is set');
|
||||||
}
|
}
|
||||||
|
@ -89,7 +89,7 @@ export async function getArcKubeconfig(): Promise<string> {
|
|||||||
}
|
}
|
||||||
console.log('Waiting for 2 minutes for kubeconfig to be merged....')
|
console.log('Waiting for 2 minutes for kubeconfig to be merged....')
|
||||||
await sleep(120000) //sleeping for 2 minutes to allow kubeconfig to be merged
|
await sleep(120000) //sleeping for 2 minutes to allow kubeconfig to be merged
|
||||||
fs.chmodSync(kubeconfigPath, '600');
|
//fs.chmodSync(kubeconfigPath, '600');
|
||||||
core.exportVariable('KUBECONFIG', kubeconfigPath);
|
core.exportVariable('KUBECONFIG', kubeconfigPath);
|
||||||
console.log('KUBECONFIG environment variable is set');
|
console.log('KUBECONFIG environment variable is set');
|
||||||
} catch (ex) {
|
} catch (ex) {
|
||||||
|
Reference in New Issue
Block a user