Attempt to use unluck we get back from lock.

This commit is contained in:
Sam Rose 2024-06-11 15:33:18 +01:00
parent af0802df30
commit 2e67ae115e
No known key found for this signature in database
1 changed files with 2 additions and 2 deletions

View File

@ -86,7 +86,7 @@ export async function startContainer(container: GenericContainer) {
fs.writeFileSync(lockPath, "")
}
await lockfile.lock(lockPath, {
const unlock = await lockfile.lock(lockPath, {
retries: 10,
})
@ -94,7 +94,7 @@ export async function startContainer(container: GenericContainer) {
try {
startedContainer = await container.start()
} finally {
await lockfile.unlock(lockPath)
await unlock()
}
const info = testContainerUtils.getContainerById(startedContainer.getId())