mirror of
https://github.com/game-ci/unity-builder.git
synced 2025-07-04 12:25:19 -04:00

- Added `runAsHostUser` to allow running the container as the same user as the host system. This fixes most permissions issues on self-hosted runners. - Perform android sdk setup during entrypoint.sh to ensure it has root permissions if the user switches to a non-root user - Automatically detect android sdk target version if parameters are not already provided to configure the sdk - Generate a new uuid for machineID to ensure separate containers are unique to reduce license activation errors - Add exponential retry strategy for Ubuntu license activations
41 lines
888 B
Bash
41 lines
888 B
Bash
#!/usr/bin/env bash
|
|
|
|
#
|
|
# Run steps
|
|
#
|
|
source /steps/set_extra_git_configs.sh
|
|
source /steps/set_gitcredential.sh
|
|
source /steps/activate.sh
|
|
|
|
# If we didn't activate successfully, exit with the exit code from the activation step.
|
|
if [[ $UNITY_EXIT_CODE -ne 0 ]]; then
|
|
exit $UNITY_EXIT_CODE
|
|
fi
|
|
|
|
source /steps/build.sh
|
|
source /steps/return_license.sh
|
|
|
|
#
|
|
# Instructions for debugging
|
|
#
|
|
|
|
if [[ $BUILD_EXIT_CODE -gt 0 ]]; then
|
|
echo ""
|
|
echo "###########################"
|
|
echo "# Failure #"
|
|
echo "###########################"
|
|
echo ""
|
|
echo "Please note that the exit code is not very descriptive."
|
|
echo "Most likely it will not help you solve the issue."
|
|
echo ""
|
|
echo "To find the reason for failure: please search for errors in the log above and check for annotations in the summary view."
|
|
echo ""
|
|
fi;
|
|
|
|
#
|
|
# Exit with code from the build step.
|
|
#
|
|
|
|
# Exiting su
|
|
exit $BUILD_EXIT_CODE
|