From 30867a032534389962955ab490bab44864a3cc8f Mon Sep 17 00:00:00 2001 From: Webber Date: Mon, 4 Nov 2019 21:48:08 +0100 Subject: [PATCH] Try to get an indication --- get-manual-license-file/Dockerfile | 14 ++++++++++++++ get-manual-license-file/README.md | 7 +++++++ get-manual-license-file/entrypoint.sh | 15 +++++++++++++++ test/entrypoint.sh | 17 ++++++++++++----- 4 files changed, 48 insertions(+), 5 deletions(-) create mode 100644 get-manual-license-file/Dockerfile create mode 100644 get-manual-license-file/README.md create mode 100644 get-manual-license-file/entrypoint.sh diff --git a/get-manual-license-file/Dockerfile b/get-manual-license-file/Dockerfile new file mode 100644 index 0000000..07583cd --- /dev/null +++ b/get-manual-license-file/Dockerfile @@ -0,0 +1,14 @@ +FROM gableroux/unity3d:2019.2.11f1 + +LABEL "com.github.actions.name"="Get Unity License File" +LABEL "com.github.actions.description"="Acquire manual license file for Unity editor" +LABEL "com.github.actions.icon"="box" +LABEL "com.github.actions.color"="gray-dark" + +LABEL "repository"="http://github.com/webbertakken/unity-actions" +LABEL "homepage"="http://github.com/webbertakken/unity-actions" +LABEL "maintainer"="Webber Takken " + +ADD entrypoint.sh /entrypoint.sh +RUN chmod +x /entrypoint.sh +ENTRYPOINT ["/entrypoint.sh"] diff --git a/get-manual-license-file/README.md b/get-manual-license-file/README.md new file mode 100644 index 0000000..8e53a0a --- /dev/null +++ b/get-manual-license-file/README.md @@ -0,0 +1,7 @@ +# Get manual license file + +Acquires manual license file for activating CI license. + +## Usage + +Unknown so far diff --git a/get-manual-license-file/entrypoint.sh b/get-manual-license-file/entrypoint.sh new file mode 100644 index 0000000..46e3dfe --- /dev/null +++ b/get-manual-license-file/entrypoint.sh @@ -0,0 +1,15 @@ +#!/usr/bin/env bash + +set -e + +xvfb-run --auto-servernum --server-args='-screen 0 640x480x24' \ + /opt/Unity/Editor/Unity \ + -batchmode \ + -nographics \ + -logFile /dev/stdout \ + -createManualActivationFile \ + +echo "Use this file for manual activation and add it to \$UNITY_LICENSE variabe." +cat Unity_v2019.2.11f1.alf + +cp Unity_v2019.2.11f1.alf $HOME/Unity_v2019.2.11f1.alf diff --git a/test/entrypoint.sh b/test/entrypoint.sh index 7525780..c4a3574 100644 --- a/test/entrypoint.sh +++ b/test/entrypoint.sh @@ -1,18 +1,25 @@ #!/usr/bin/env bash -set -x +set -e echo "$UNITY_LICENSE" > /root/.local/share/unity3d/Unity/Unity_lic.ulf +set -x + echo "Testing for $TEST_PLATFORM" ${UNITY_EXECUTABLE:-xvfb-run --auto-servernum --server-args='-screen 0 640x480x24' /opt/Unity/Editor/Unity} \ - -projectPath $(pwd) \ + -batchmode \ + -nographics \ + -logFile /dev/stdout \ + -batchmode \ + -nographics \ + -verbose \ + -quit \ + -projectPath $GITHUB_WORKSPACE \ -runTests \ -testPlatform $TEST_PLATFORM \ - -testResults $(pwd)/$TEST_PLATFORM-results.xml \ - -logFile /dev/stdout \ - -batchmode + -testResults $GITHUB_WORKSPACE/$TEST_PLATFORM-results.xml UNITY_EXIT_CODE=$?