mirror of
https://github.com/stan220/testcontainers-php.git
synced 2026-09-12 07:29:45 +00:00
fixes and improvements
This commit is contained in:
@@ -232,10 +232,12 @@ class GenericContainer implements TestContainer
|
||||
$this->id = $containerCreateResponse?->getId() ?? '';
|
||||
} catch (ContainerCreateNotFoundException) {
|
||||
/** @var CreateImageStream $imageCreateResponse */
|
||||
$this->dockerClient->imageCreate(null, [
|
||||
$imageCreateResponse = $this->dockerClient->imageCreate(null, [
|
||||
'fromImage' => explode(':', $this->image)[0],
|
||||
'tag' => explode(':', $this->image)[1] ?? 'latest',
|
||||
]);
|
||||
$imageCreateResponse->wait();
|
||||
|
||||
return $this->start();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user