feat: upgrade to images of version 1 (rolling tag) (#93)

This commit is contained in:
Webber Takken
2022-04-03 17:59:02 +02:00
committed by GitHub
parent 38e7f4ce44
commit 33cd3ea96f
5 changed files with 8 additions and 6 deletions

View File

@@ -8,4 +8,6 @@ fi
yarn lint-staged yarn lint-staged
yarn lint yarn lint
yarn test yarn test
yarn build yarn build
git add dist

4
dist/index.js generated vendored
View File

@@ -278,7 +278,7 @@ class ImageTag {
} }
} }
get tag() { get tag() {
return `${this.version}-${this.builderPlatform}`.replace(/-+$/, ''); return `ubuntu-${this.version}-${this.builderPlatform}`.replace(/-+$/, '');
} }
get image() { get image() {
return `${this.repository}/${this.name}`.replace(/^\/+/, ''); return `${this.repository}/${this.name}`.replace(/^\/+/, '');
@@ -288,7 +288,7 @@ class ImageTag {
if (customImage && customImage !== '') { if (customImage && customImage !== '') {
return customImage; return customImage;
} }
const dockerRepoVersion = 0; const dockerRepoVersion = 1;
return `${image}:${tag}-${dockerRepoVersion}`; return `${image}:${tag}-${dockerRepoVersion}`;
} }
} }

2
dist/index.js.map generated vendored

File diff suppressed because one or more lines are too long

View File

@@ -16,7 +16,7 @@ describe('ImageTag', () => {
it('returns the correct version', () => { it('returns the correct version', () => {
const image = new ImageTag('2099.1.1111'); const image = new ImageTag('2099.1.1111');
expect(image.toString()).toStrictEqual(`unityci/editor:2099.1.1111-linux-il2cpp-0`); expect(image.toString()).toStrictEqual(`unityci/editor:ubuntu-2099.1.1111-linux-il2cpp-1`);
}); });
}); });
}); });

View File

@@ -103,7 +103,7 @@ class ImageTag {
} }
get tag() { get tag() {
return `${this.version}-${this.builderPlatform}`.replace(/-+$/, ''); return `ubuntu-${this.version}-${this.builderPlatform}`.replace(/-+$/, '');
} }
get image() { get image() {
@@ -117,7 +117,7 @@ class ImageTag {
return customImage; return customImage;
} }
const dockerRepoVersion = 0; const dockerRepoVersion = 1;
return `${image}:${tag}-${dockerRepoVersion}`; return `${image}:${tag}-${dockerRepoVersion}`;
} }
} }