mirror of
https://github.com/game-ci/unity-builder.git
synced 2025-07-07 20:35:33 -04:00
log file path
This commit is contained in:
parent
1df6a12ca4
commit
d3b4f28e32
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.
@ -15,7 +15,7 @@ import BuildParameters from '../../build-parameters';
|
|||||||
|
|
||||||
export class RemoteClient {
|
export class RemoteClient {
|
||||||
@CliFunction(`remote-cli-pre-build`, `sets up a repository, usually before a game-ci build`)
|
@CliFunction(`remote-cli-pre-build`, `sets up a repository, usually before a game-ci build`)
|
||||||
static async runRemoteClientJob() {
|
static async setupRemoteClient() {
|
||||||
CloudRunnerLogger.log(`bootstrap game ci cloud runner...`);
|
CloudRunnerLogger.log(`bootstrap game ci cloud runner...`);
|
||||||
if (!(await RemoteClient.handleRetainedWorkspace())) {
|
if (!(await RemoteClient.handleRetainedWorkspace())) {
|
||||||
await RemoteClient.bootstrapRepository();
|
await RemoteClient.bootstrapRepository();
|
||||||
@ -23,9 +23,27 @@ export class RemoteClient {
|
|||||||
await RemoteClient.replaceLargePackageReferencesWithSharedReferences();
|
await RemoteClient.replaceLargePackageReferencesWithSharedReferences();
|
||||||
await RemoteClient.runCustomHookFiles(`before-build`);
|
await RemoteClient.runCustomHookFiles(`before-build`);
|
||||||
}
|
}
|
||||||
|
@CliFunction(`remote-cli-build`, `sets up a repository, usually before a game-ci build`)
|
||||||
|
static async remoteClientBuild() {
|
||||||
|
CloudRunnerLogger.log(`bootstrap game ci cloud runner...`);
|
||||||
|
const distFolder = path.join(CloudRunnerFolders.builderPathAbsolute, 'dist');
|
||||||
|
const ubuntuPlatformsFolder = path.join(CloudRunnerFolders.builderPathAbsolute, 'dist', 'platforms', 'ubuntu');
|
||||||
|
CloudRunnerSystem.Run(`mkdir -p ${`${CloudRunnerFolders.ToLinuxFolder(
|
||||||
|
CloudRunnerFolders.projectBuildFolderAbsolute,
|
||||||
|
)}/build`}
|
||||||
|
cd ${CloudRunnerFolders.ToLinuxFolder(CloudRunnerFolders.projectPathAbsolute)}
|
||||||
|
cp -r "${CloudRunnerFolders.ToLinuxFolder(path.join(distFolder, 'default-build-script'))}" "/UnityBuilderAction"
|
||||||
|
cp -r "${CloudRunnerFolders.ToLinuxFolder(path.join(ubuntuPlatformsFolder, 'entrypoint.sh'))}" "/entrypoint.sh"
|
||||||
|
cp -r "${CloudRunnerFolders.ToLinuxFolder(path.join(ubuntuPlatformsFolder, 'steps'))}" "/steps"
|
||||||
|
chmod -R +x "/entrypoint.sh"
|
||||||
|
chmod -R +x "/steps"
|
||||||
|
echo "game ci start"
|
||||||
|
/entrypoint.sh
|
||||||
|
echo "game ci caching results"`);
|
||||||
|
}
|
||||||
|
|
||||||
@CliFunction(`remote-cli-post-build`, `runs a cloud runner build`)
|
@CliFunction(`remote-cli-post-build`, `runs a cloud runner build`)
|
||||||
public static async PostCLIBuild(): Promise<string> {
|
public static async remoteClientPostBuild(): Promise<string> {
|
||||||
RemoteClientLogger.log(`Running POST build tasks`);
|
RemoteClientLogger.log(`Running POST build tasks`);
|
||||||
|
|
||||||
await Caching.PushToCache(
|
await Caching.PushToCache(
|
||||||
|
@ -97,21 +97,8 @@ node ${builderPath} -m remote-cli-pre-build`;
|
|||||||
}
|
}
|
||||||
|
|
||||||
private static BuildCommands(builderPath: string) {
|
private static BuildCommands(builderPath: string) {
|
||||||
const distFolder = path.join(CloudRunnerFolders.builderPathAbsolute, 'dist');
|
|
||||||
const ubuntuPlatformsFolder = path.join(CloudRunnerFolders.builderPathAbsolute, 'dist', 'platforms', 'ubuntu');
|
|
||||||
|
|
||||||
return `echo "game ci cloud runner initalized"
|
return `echo "game ci cloud runner initalized"
|
||||||
mkdir -p ${`${CloudRunnerFolders.ToLinuxFolder(CloudRunnerFolders.projectBuildFolderAbsolute)}/build`}
|
node ${builderPath} -m remote-cli-build
|
||||||
cd ${CloudRunnerFolders.ToLinuxFolder(CloudRunnerFolders.projectPathAbsolute)}
|
|
||||||
cp -r "${CloudRunnerFolders.ToLinuxFolder(path.join(distFolder, 'default-build-script'))}" "/UnityBuilderAction"
|
|
||||||
cp -r "${CloudRunnerFolders.ToLinuxFolder(path.join(ubuntuPlatformsFolder, 'entrypoint.sh'))}" "/entrypoint.sh"
|
|
||||||
cp -r "${CloudRunnerFolders.ToLinuxFolder(path.join(ubuntuPlatformsFolder, 'steps'))}" "/steps"
|
|
||||||
chmod -R +x "/entrypoint.sh"
|
|
||||||
chmod -R +x "/steps"
|
|
||||||
echo "game ci start"
|
|
||||||
/entrypoint.sh
|
|
||||||
echo "game ci caching results"
|
|
||||||
chmod +x ${builderPath}
|
|
||||||
node ${builderPath} -m remote-cli-post-build`;
|
node ${builderPath} -m remote-cli-post-build`;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user