mirror of
https://github.com/game-ci/unity-builder.git
synced 2025-07-04 12:25:19 -04:00
Minor tweaks and corrections for cloud runner pipeline and branch parameter (#351)
* Update cloud-runner-aws-pipeline.yml * Update cloud-runner-k8s-pipeline.yml * yarn build * yarn build * correct branch ref * correct branch ref passed to target repo * Create k8s-tests.yml * Delete k8s-tests.yml * correct branch ref passed to target repo * correct branch ref passed to target repo
This commit is contained in:
parent
693ff829de
commit
d975f3b80f
@ -1,7 +1,7 @@
|
|||||||
name: Cloud Runner - AWS Tests
|
name: Cloud Runner - AWS Tests
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push: { branches: [main, aws, remote-builder/unified-providers] }
|
push: { branches: [main, cloud-runner-develop] }
|
||||||
|
|
||||||
env:
|
env:
|
||||||
GKE_ZONE: 'us-central1'
|
GKE_ZONE: 'us-central1'
|
||||||
@ -15,7 +15,7 @@ env:
|
|||||||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
||||||
AWS_DEFAULT_REGION: eu-west-2
|
AWS_DEFAULT_REGION: eu-west-2
|
||||||
AWS_BASE_STACK_NAME: game-ci-github-pipelines
|
AWS_BASE_STACK_NAME: game-ci-github-pipelines
|
||||||
CLOUD_RUNNER_BRANCH: remote-builder/unified-providers
|
CLOUD_RUNNER_BRANCH: ${{ github.ref }}
|
||||||
CLOUD_RUNNER_TESTS: true
|
CLOUD_RUNNER_TESTS: true
|
||||||
DEBUG: true
|
DEBUG: true
|
||||||
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
|
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
name: Cloud Runner - K8s Tests
|
name: Cloud Runner - K8s Tests
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push: { branches: [remote-builder/k8s, remote-builder/unified-providers] }
|
push: { branches: [cloud-runner-develop] }
|
||||||
# push: { branches: [main] }
|
# push: { branches: [main] }
|
||||||
# pull_request:
|
# pull_request:
|
||||||
# paths-ignore:
|
# paths-ignore:
|
||||||
@ -20,7 +20,7 @@ env:
|
|||||||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
||||||
AWS_DEFAULT_REGION: eu-west-2
|
AWS_DEFAULT_REGION: eu-west-2
|
||||||
AWS_BASE_STACK_NAME: game-ci-github-pipelines
|
AWS_BASE_STACK_NAME: game-ci-github-pipelines
|
||||||
CLOUD_RUNNER_BRANCH: remote-builder/unified-providers
|
CLOUD_RUNNER_BRANCH: ${{ github.ref }}
|
||||||
CLOUD_RUNNER_TESTS: true
|
CLOUD_RUNNER_TESTS: true
|
||||||
DEBUG: true
|
DEBUG: true
|
||||||
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
|
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
|
||||||
|
BIN
dist/index.js
generated
vendored
BIN
dist/index.js
generated
vendored
Binary file not shown.
BIN
dist/index.js.map
generated
vendored
BIN
dist/index.js.map
generated
vendored
Binary file not shown.
@ -55,7 +55,7 @@ export class SetupCloudRunnerRepository {
|
|||||||
RemoteClientLogger.log(`Cloning the repository being built:`);
|
RemoteClientLogger.log(`Cloning the repository being built:`);
|
||||||
await CloudRunnerSystem.Run(`git lfs install --skip-smudge`);
|
await CloudRunnerSystem.Run(`git lfs install --skip-smudge`);
|
||||||
await CloudRunnerSystem.Run(
|
await CloudRunnerSystem.Run(
|
||||||
`git clone ${CloudRunnerState.targetBuildRepoUrl} ${path.resolve(
|
`git clone -b ${CloudRunnerState.branchName} ${CloudRunnerState.targetBuildRepoUrl} ${path.resolve(
|
||||||
`..`,
|
`..`,
|
||||||
path.basename(CloudRunnerState.repoPathFull),
|
path.basename(CloudRunnerState.repoPathFull),
|
||||||
)}`,
|
)}`,
|
||||||
|
@ -21,6 +21,12 @@ export class SetupStep implements StepInterface {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static getCloudRunnerBranch() {
|
||||||
|
return process.env.CLOUD_RUNNER_BRANCH?.includes('/')
|
||||||
|
? process.env.CLOUD_RUNNER_BRANCH.split('/').reverse()[0]
|
||||||
|
: process.env.CLOUD_RUNNER_BRANCH;
|
||||||
|
}
|
||||||
|
|
||||||
private static async downloadRepository(
|
private static async downloadRepository(
|
||||||
image: string,
|
image: string,
|
||||||
environmentVariables: CloudRunnerEnvironmentVariable[],
|
environmentVariables: CloudRunnerEnvironmentVariable[],
|
||||||
@ -38,7 +44,7 @@ export class SetupStep implements StepInterface {
|
|||||||
${hooks.filter((x) => x.hook.includes(`before`)).map((x) => x.commands) || ' '}
|
${hooks.filter((x) => x.hook.includes(`before`)).map((x) => x.commands) || ' '}
|
||||||
export GIT_DISCOVERY_ACROSS_FILESYSTEM=1
|
export GIT_DISCOVERY_ACROSS_FILESYSTEM=1
|
||||||
mkdir -p ${CloudRunnerState.builderPathFull.replace(/\\/g, `/`)}
|
mkdir -p ${CloudRunnerState.builderPathFull.replace(/\\/g, `/`)}
|
||||||
git clone -q -b ${CloudRunnerState.branchName} ${
|
git clone -q -b ${SetupStep.getCloudRunnerBranch()} ${
|
||||||
CloudRunnerState.unityBuilderRepoUrl
|
CloudRunnerState.unityBuilderRepoUrl
|
||||||
} "${CloudRunnerState.builderPathFull.replace(/\\/g, `/`)}"
|
} "${CloudRunnerState.builderPathFull.replace(/\\/g, `/`)}"
|
||||||
${Input.cloudRunnerTests ? '' : '#'} tree ${CloudRunnerState.builderPathFull.replace(/\\/g, `/`)}
|
${Input.cloudRunnerTests ? '' : '#'} tree ${CloudRunnerState.builderPathFull.replace(/\\/g, `/`)}
|
||||||
|
Loading…
Reference in New Issue
Block a user