fix reversed caching direction of cache-push
parent
86e4c7c856
commit
412578be66
|
|
@ -104,8 +104,8 @@ jobs:
|
|||
aws s3 ls
|
||||
aws s3 ls game-ci-test-storage
|
||||
ls /data/cache/$BRANCH
|
||||
echo "/data/cache/$BRANCH/build-$BUILD_GUID.zip s3://game-ci-test-storage/$BRANCH/$BUILD_FILE"
|
||||
aws s3 cp /data/cache/$BRANCH/build-$BUILD_GUID.zip s3://game-ci-test-storage/$BRANCH/build-$BUILD_GUID.zip
|
||||
echo "/data/cache/build/$BRANCH/build-$BUILD_GUID.zip s3://game-ci-test-storage/$BRANCH/$BUILD_FILE"
|
||||
aws s3 cp /data/cache/build/$BRANCH/build-$BUILD_GUID.zip s3://game-ci-test-storage/$BRANCH/build-$BUILD_GUID.zip
|
||||
secrets:
|
||||
- name: awsAccessKeyId
|
||||
value: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
||||
|
|
|
|||
|
|
@ -587,7 +587,7 @@ class CLI {
|
|||
`);
|
||||
__1.CloudRunner.buildParameters = buildParameter;
|
||||
cloud_runner_logger_1.default.log(`${CLI.options['cachePushFrom']} ${CLI.options['cachePushTo']} ${CLI.options['artifactName']}`);
|
||||
yield caching_1.Caching.PushToCache(CLI.options['cachePushFrom'], CLI.options['cachePushTo'], CLI.options['artifactName']);
|
||||
yield caching_1.Caching.PushToCache(CLI.options['cachePushTo'], CLI.options['cachePushFrom'], CLI.options['artifactName']);
|
||||
}
|
||||
catch (error) {
|
||||
cloud_runner_logger_1.default.log(`${error}`);
|
||||
|
|
@ -1010,18 +1010,12 @@ class SetupCloudRunnerRepository {
|
|||
}
|
||||
static pullLatestLFS() {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
if (cloud_runner_1.default.buildParameters.cloudRunnerIntegrationTests) {
|
||||
yield cloud_runner_system_1.CloudRunnerSystem.Run(`ls -lh ${cloud_runner_folders_1.CloudRunnerFolders.lfsDirectoryFull}/..`);
|
||||
}
|
||||
process.chdir(cloud_runner_folders_1.CloudRunnerFolders.repoPathFull);
|
||||
yield cloud_runner_system_1.CloudRunnerSystem.Run(`git config --global filter.lfs.smudge "git-lfs smudge -- %f"`);
|
||||
yield cloud_runner_system_1.CloudRunnerSystem.Run(`git config --global filter.lfs.process "git-lfs filter-process"`);
|
||||
yield cloud_runner_system_1.CloudRunnerSystem.Run(`git lfs pull`);
|
||||
remote_client_logger_1.RemoteClientLogger.log(`pulled latest LFS files`);
|
||||
console_1.assert(fs_1.default.existsSync(cloud_runner_folders_1.CloudRunnerFolders.lfsDirectoryFull));
|
||||
if (cloud_runner_1.default.buildParameters.cloudRunnerIntegrationTests) {
|
||||
yield cloud_runner_system_1.CloudRunnerSystem.Run(`ls -lh ${cloud_runner_folders_1.CloudRunnerFolders.lfsDirectoryFull}/..`);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
@ -1888,13 +1882,13 @@ class CloudRunner {
|
|||
CloudRunner.setup(buildParameters);
|
||||
try {
|
||||
if (!CloudRunner.buildParameters.cliMode)
|
||||
core.startGroup('Setup remote runner');
|
||||
core.startGroup('Setup shared cloud runner resources');
|
||||
yield CloudRunner.CloudRunnerProviderPlatform.setupSharedResources(CloudRunner.buildParameters.buildGuid, CloudRunner.buildParameters, CloudRunner.buildParameters.branch, CloudRunner.defaultSecrets);
|
||||
if (!CloudRunner.buildParameters.cliMode)
|
||||
core.endGroup();
|
||||
const output = yield new workflow_composition_root_1.WorkflowCompositionRoot().run(new cloud_runner_step_state_1.CloudRunnerStepState(baseImage, CloudRunner.cloudRunnerEnvironmentVariables, CloudRunner.defaultSecrets));
|
||||
if (!CloudRunner.buildParameters.cliMode)
|
||||
core.startGroup('Cleanup');
|
||||
core.startGroup('Cleanup shared cloud runner resources');
|
||||
yield CloudRunner.CloudRunnerProviderPlatform.cleanupSharedResources(CloudRunner.buildParameters.buildGuid, CloudRunner.buildParameters, CloudRunner.buildParameters.branch, CloudRunner.defaultSecrets);
|
||||
cloud_runner_logger_1.default.log(`Cleanup complete`);
|
||||
if (!CloudRunner.buildParameters.cliMode)
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
|
|
@ -107,7 +107,7 @@ export class CLI {
|
|||
CloudRunnerLogger.log(
|
||||
`${CLI.options['cachePushFrom']} ${CLI.options['cachePushTo']} ${CLI.options['artifactName']}`,
|
||||
);
|
||||
await Caching.PushToCache(CLI.options['cachePushFrom'], CLI.options['cachePushTo'], CLI.options['artifactName']);
|
||||
await Caching.PushToCache(CLI.options['cachePushTo'], CLI.options['cachePushFrom'], CLI.options['artifactName']);
|
||||
} catch (error: any) {
|
||||
CloudRunnerLogger.log(`${error}`);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -74,18 +74,11 @@ export class SetupCloudRunnerRepository {
|
|||
}
|
||||
|
||||
private static async pullLatestLFS() {
|
||||
if (CloudRunner.buildParameters.cloudRunnerIntegrationTests) {
|
||||
await CloudRunnerSystem.Run(`ls -lh ${CloudRunnerFolders.lfsDirectoryFull}/..`);
|
||||
}
|
||||
process.chdir(CloudRunnerFolders.repoPathFull);
|
||||
await CloudRunnerSystem.Run(`git config --global filter.lfs.smudge "git-lfs smudge -- %f"`);
|
||||
await CloudRunnerSystem.Run(`git config --global filter.lfs.process "git-lfs filter-process"`);
|
||||
await CloudRunnerSystem.Run(`git lfs pull`);
|
||||
RemoteClientLogger.log(`pulled latest LFS files`);
|
||||
assert(fs.existsSync(CloudRunnerFolders.lfsDirectoryFull));
|
||||
|
||||
if (CloudRunner.buildParameters.cloudRunnerIntegrationTests) {
|
||||
await CloudRunnerSystem.Run(`ls -lh ${CloudRunnerFolders.lfsDirectoryFull}/..`);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ class CloudRunner {
|
|||
static async run(buildParameters: BuildParameters, baseImage: string) {
|
||||
CloudRunner.setup(buildParameters);
|
||||
try {
|
||||
if (!CloudRunner.buildParameters.cliMode) core.startGroup('Setup remote runner');
|
||||
if (!CloudRunner.buildParameters.cliMode) core.startGroup('Setup shared cloud runner resources');
|
||||
await CloudRunner.CloudRunnerProviderPlatform.setupSharedResources(
|
||||
CloudRunner.buildParameters.buildGuid,
|
||||
CloudRunner.buildParameters,
|
||||
|
|
@ -67,7 +67,7 @@ class CloudRunner {
|
|||
const output = await new WorkflowCompositionRoot().run(
|
||||
new CloudRunnerStepState(baseImage, CloudRunner.cloudRunnerEnvironmentVariables, CloudRunner.defaultSecrets),
|
||||
);
|
||||
if (!CloudRunner.buildParameters.cliMode) core.startGroup('Cleanup');
|
||||
if (!CloudRunner.buildParameters.cliMode) core.startGroup('Cleanup shared cloud runner resources');
|
||||
await CloudRunner.CloudRunnerProviderPlatform.cleanupSharedResources(
|
||||
CloudRunner.buildParameters.buildGuid,
|
||||
CloudRunner.buildParameters,
|
||||
|
|
|
|||
Loading…
Reference in New Issue