fixes
parent
b36d1a0db6
commit
443b682da6
|
|
@ -500,6 +500,7 @@ const setup_cloud_runner_repository_1 = __nccwpck_require__(39656);
|
|||
const SDK = __importStar(__nccwpck_require__(71786));
|
||||
const caching_1 = __nccwpck_require__(38759);
|
||||
const cloud_runner_query_override_1 = __importDefault(__nccwpck_require__(31011));
|
||||
const lfs_hashing_1 = __nccwpck_require__(31938);
|
||||
class CLI {
|
||||
static get cliMode() {
|
||||
return CLI.options !== undefined && CLI.options.mode !== undefined && CLI.options.mode !== '';
|
||||
|
|
@ -622,6 +623,12 @@ class CLI {
|
|||
cloud_runner_logger_1.default.log(JSON.stringify(yield ecs.describeClusters().promise(), undefined, 4));
|
||||
});
|
||||
}
|
||||
static hash() {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
const folder = CLI.options['cachePushFrom'];
|
||||
lfs_hashing_1.LFSHashing.hashAllFiles(folder);
|
||||
});
|
||||
}
|
||||
}
|
||||
__decorate([
|
||||
cli_decorator_1.CliFunction(`cli`, `runs a cloud runner build`)
|
||||
|
|
@ -638,6 +645,9 @@ __decorate([
|
|||
__decorate([
|
||||
cli_decorator_1.CliFunction(`garbage-collect-aws`, `garbage collect aws`)
|
||||
], CLI, "garbageCollectAws", null);
|
||||
__decorate([
|
||||
cli_decorator_1.CliFunction(`hash`, `hash all folder contents`)
|
||||
], CLI, "hash", null);
|
||||
exports.CLI = CLI;
|
||||
|
||||
|
||||
|
|
@ -1001,6 +1011,7 @@ class SetupCloudRunnerRepository {
|
|||
return __awaiter(this, void 0, void 0, function* () {
|
||||
cloud_runner_logger_1.default.log(`Size of ${message}`);
|
||||
yield cloud_runner_system_1.CloudRunnerSystem.Run(`du -sh ${folder}`);
|
||||
yield cloud_runner_system_1.CloudRunnerSystem.Run(`du -h ${folder}`);
|
||||
});
|
||||
}
|
||||
static cloneRepoWithoutLFSFiles() {
|
||||
|
|
@ -3463,7 +3474,6 @@ class BuildAutomationWorkflow {
|
|||
node ${builderPath} -m remote-cli`;
|
||||
}
|
||||
static BuildCommands(builderPath) {
|
||||
const guid = cloud_runner_1.default.buildParameters.buildGuid;
|
||||
const linuxCacheFolder = cloud_runner_folders_1.CloudRunnerFolders.cacheFolderFull.replace(/\\/g, `/`);
|
||||
const distFolder = path_1.default.join(cloud_runner_folders_1.CloudRunnerFolders.builderPathFull, 'dist');
|
||||
const ubuntuPlatformsFolder = path_1.default.join(cloud_runner_folders_1.CloudRunnerFolders.builderPathFull, 'dist', 'platforms', 'ubuntu');
|
||||
|
|
@ -3477,9 +3487,9 @@ class BuildAutomationWorkflow {
|
|||
/entrypoint.sh
|
||||
echo "game ci cloud runner push library to cache"
|
||||
chmod +x ${builderPath}
|
||||
node ${builderPath} -m cache-push --cachePushFrom Library --artifactName lib-${guid} --cachePushTo ${linuxCacheFolder}/Library
|
||||
node ${builderPath} -m cache-push --cachePushFrom Library --cachePushTo ${linuxCacheFolder}/Library
|
||||
echo "game ci cloud runner push build to cache"
|
||||
node ${builderPath} -m cache-push --cachePushFrom build --artifactName build-${guid} --cachePushTo ${linuxCacheFolder}/build`;
|
||||
node ${builderPath} -m cache-push --cachePushFrom build --cachePushTo ${linuxCacheFolder}/build`;
|
||||
}
|
||||
}
|
||||
exports.BuildAutomationWorkflow = BuildAutomationWorkflow;
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
|
|
@ -9,6 +9,7 @@ import { SetupCloudRunnerRepository } from './remote-client/setup-cloud-runner-r
|
|||
import * as SDK from 'aws-sdk';
|
||||
import { Caching } from './remote-client/remote-client-services/caching';
|
||||
import CloudRunnerQueryOverride from '../cloud-runner/services/cloud-runner-query-override';
|
||||
import { LFSHashing } from './remote-client/remote-client-services/lfs-hashing';
|
||||
|
||||
export class CLI {
|
||||
public static options;
|
||||
|
|
@ -144,4 +145,10 @@ export class CLI {
|
|||
CloudRunnerLogger.log(JSON.stringify(await ecs.listClusters().promise(), undefined, 4));
|
||||
CloudRunnerLogger.log(JSON.stringify(await ecs.describeClusters().promise(), undefined, 4));
|
||||
}
|
||||
|
||||
@CliFunction(`hash`, `hash all folder contents`)
|
||||
static async hash() {
|
||||
const folder = CLI.options['cachePushFrom'];
|
||||
LFSHashing.hashAllFiles(folder);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -46,6 +46,7 @@ export class SetupCloudRunnerRepository {
|
|||
private static async sizeOfFolder(message: string, folder: string) {
|
||||
CloudRunnerLogger.log(`Size of ${message}`);
|
||||
await CloudRunnerSystem.Run(`du -sh ${folder}`);
|
||||
await CloudRunnerSystem.Run(`du -h ${folder}`);
|
||||
}
|
||||
|
||||
private static async cloneRepoWithoutLFSFiles() {
|
||||
|
|
|
|||
|
|
@ -95,7 +95,6 @@ export class BuildAutomationWorkflow implements WorkflowInterface {
|
|||
}
|
||||
|
||||
private static BuildCommands(builderPath) {
|
||||
const guid = CloudRunner.buildParameters.buildGuid;
|
||||
const linuxCacheFolder = CloudRunnerFolders.cacheFolderFull.replace(/\\/g, `/`);
|
||||
const distFolder = path.join(CloudRunnerFolders.builderPathFull, 'dist');
|
||||
const ubuntuPlatformsFolder = path.join(CloudRunnerFolders.builderPathFull, 'dist', 'platforms', 'ubuntu');
|
||||
|
|
@ -109,8 +108,8 @@ export class BuildAutomationWorkflow implements WorkflowInterface {
|
|||
/entrypoint.sh
|
||||
echo "game ci cloud runner push library to cache"
|
||||
chmod +x ${builderPath}
|
||||
node ${builderPath} -m cache-push --cachePushFrom Library --artifactName lib-${guid} --cachePushTo ${linuxCacheFolder}/Library
|
||||
node ${builderPath} -m cache-push --cachePushFrom Library --cachePushTo ${linuxCacheFolder}/Library
|
||||
echo "game ci cloud runner push build to cache"
|
||||
node ${builderPath} -m cache-push --cachePushFrom build --artifactName build-${guid} --cachePushTo ${linuxCacheFolder}/build`;
|
||||
node ${builderPath} -m cache-push --cachePushFrom build --cachePushTo ${linuxCacheFolder}/build`;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue