Merge pull request #480 from vvoland/docker-install-image-latest-fix
Some checks failed
publish / publish (push) Has been cancelled

docker/install: Fix latest image install on lima
This commit is contained in:
CrazyMax
2024-10-30 16:22:35 +01:00
committed by GitHub
6 changed files with 76 additions and 28 deletions

View File

@@ -14,7 +14,7 @@
* limitations under the License.
*/
import {jest, describe, expect, test, beforeEach, afterEach} from '@jest/globals';
import {jest, describe, test, beforeEach, afterEach, expect} from '@jest/globals';
import fs from 'fs';
import os from 'os';
import path from 'path';
@@ -43,6 +43,7 @@ aarch64:https://cloud.debian.org/images/cloud/bookworm/20231013-1532/debian-12-g
test.each([
{type: 'image', tag: '27.3.1'} as InstallSourceImage,
{type: 'image', tag: 'master'} as InstallSourceImage,
{type: 'image', tag: 'latest'} as InstallSourceImage,
{type: 'archive', version: 'v26.1.4', channel: 'stable'} as InstallSourceArchive,
{type: 'archive', version: 'latest', channel: 'stable'} as InstallSourceArchive,
])(
@@ -65,12 +66,17 @@ aarch64:https://cloud.debian.org/images/cloud/bookworm/20231013-1532/debian-12-g
daemonConfig: `{"debug":true,"features":{"containerd-snapshotter":true}}`
});
await expect((async () => {
await install.download();
await install.install();
await Docker.printVersion();
await Docker.printInfo();
})().finally(async () => {
await install.tearDown();
})).resolves.not.toThrow();
try {
await install.download();
await install.install();
await Docker.printVersion();
await Docker.printInfo();
} catch (error) {
console.error(error);
throw error;
} finally {
await install.tearDown();
}
})()).resolves.not.toThrow();
}, 30 * 60 * 1000);
});