docker repo migrated (#77)

pull/82/head v2.0-alpha-1
Devashish Lal 2020-11-26 22:49:17 +05:30 committed by GitHub
parent 679222c549
commit 31cd755121
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 51 additions and 51 deletions

File diff suppressed because one or more lines are too long

View File

@ -24,8 +24,7 @@ if [[ -n "$UNITY_LICENSE" ]] || [[ -n "$UNITY_LICENSE_FILE" ]]; then
fi
# Activate license
ACTIVATION_OUTPUT=$(xvfb-run --auto-servernum --server-args='-screen 0 640x480x24' \
/opt/Unity/Editor/Unity \
ACTIVATION_OUTPUT=$(unity-editor \
-batchmode \
-nographics \
-logFile /dev/stdout \
@ -63,8 +62,7 @@ elif [[ -n "$UNITY_SERIAL" && -n "$UNITY_EMAIL" && -n "$UNITY_PASSWORD" ]]; then
echo "Requesting activation (professional license)"
# Activate license
xvfb-run --auto-servernum --server-args='-screen 0 640x480x24' \
/opt/Unity/Editor/Unity \
unity-editor \
-batchmode \
-nographics \
-logFile /dev/stdout \

View File

@ -6,8 +6,7 @@ if [[ -n "$UNITY_SERIAL" ]]; then
#
# This will return the license that is currently in use.
#
xvfb-run --auto-servernum --server-args='-screen 0 640x480x24' \
/opt/Unity/Editor/Unity \
unity-editor \
-batchmode \
-nographics \
-logFile /dev/stdout \

View File

@ -74,8 +74,7 @@ if [ $EDIT_MODE = true ]; then
echo "# Testing in EditMode #"
echo "###########################"
echo ""
xvfb-run --auto-servernum --server-args='-screen 0 640x480x24' \
/opt/Unity/Editor/Unity \
unity-editor \
-batchmode \
-logFile "$FULL_ARTIFACTS_PATH/editmode.log" \
-projectPath "$UNITY_PROJECT_PATH" \
@ -112,8 +111,7 @@ if [ $PLAY_MODE = true ]; then
echo "# Testing in PlayMode #"
echo "###########################"
echo ""
xvfb-run --auto-servernum --server-args='-screen 0 640x480x24' \
/opt/Unity/Editor/Unity \
unity-editor \
-batchmode \
-logFile "$FULL_ARTIFACTS_PATH/playmode.log" \
-projectPath "$UNITY_PROJECT_PATH" \

View File

@ -6,15 +6,20 @@ describe('Docker', () => {
it('builds', async () => {
const path = Action.actionFolder;
const dockerfile = `${path}/Dockerfile`;
const baseImage = new ImageTag({
const image = new ImageTag({
repository: '',
name: 'alpine',
version: '3',
});
const baseImage = {
toString: () => image.toString().slice(0, image.toString().lastIndexOf('-base-0')),
version: image.version,
};
const tag = await Docker.build({ path, dockerfile, baseImage }, true);
expect(tag).toBeInstanceOf(ImageTag);
expect(tag.toString()).toStrictEqual('unity-action:3');
expect(tag.toString()).toStrictEqual('unity-action:3-base-0');
}, 240000);
});

View File

@ -2,8 +2,8 @@ import { trimStart } from 'lodash-es';
class ImageTag {
static createForBase({ version, customImage }) {
const repository = 'gableroux';
const name = 'unity3d';
const repository = 'unityci';
const name = 'editor';
return new this({ repository, name, version, customImage });
}
@ -38,7 +38,7 @@ class ImageTag {
return this.customImage;
}
return `${this.image}:${this.tag}`;
return `${this.image}:${this.tag}-base-0`;
}
}

View File

@ -32,7 +32,7 @@ describe('UnityImageVersion', () => {
it('returns the correct version', () => {
const image = ImageTag.createForBase({ version: '2099.1.1111' });
expect(image.toString()).toStrictEqual(`gableroux/unity3d:2099.1.1111`);
expect(image.toString()).toStrictEqual(`unityci/editor:2099.1.1111-base-0`);
});
it('returns customImage if given', () => {