fix: when to pull image
This commit is contained in:
parent
7cec6330cf
commit
c866213f34
@ -1096,21 +1096,19 @@ COPY ./nginx.conf /etc/nginx/conf.d/default.conf");
|
|||||||
|
|
||||||
private function start_by_compose_file()
|
private function start_by_compose_file()
|
||||||
{
|
{
|
||||||
if (
|
if ($this->application->dockerfile || $this->application->build_pack === 'dockerfile') {
|
||||||
!$this->application->dockerfile &&
|
$this->execute_remote_command(
|
||||||
(
|
["echo -n 'Starting application (could take a while).'"],
|
||||||
$this->application->build_pack === 'dockerimage' ||
|
[executeInDocker($this->deployment_uuid, "docker compose --project-directory {$this->workdir} up --build -d"), "hidden" => true],
|
||||||
$this->application->build_pack === 'dockerfile')
|
);
|
||||||
) {
|
} else if ($this->application->build_pack === 'dockerimage') {
|
||||||
$this->execute_remote_command(
|
$this->execute_remote_command(
|
||||||
["echo -n 'Pulling latest images from the registry.'"],
|
["echo -n 'Pulling latest images from the registry.'"],
|
||||||
[executeInDocker($this->deployment_uuid, "docker compose --project-directory {$this->workdir}"), "hidden" => true],
|
[executeInDocker($this->deployment_uuid, "docker compose --project-directory {$this->workdir} pull"), "hidden" => true],
|
||||||
|
["echo -n 'Starting application (could take a while).'"],
|
||||||
|
[executeInDocker($this->deployment_uuid, "docker compose --project-directory {$this->workdir} up --build -d"), "hidden" => true],
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
$this->execute_remote_command(
|
|
||||||
["echo -n 'Starting application (could take a while).'"],
|
|
||||||
[executeInDocker($this->deployment_uuid, "docker compose --project-directory {$this->workdir} up --build -d"), "hidden" => true],
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private function generate_build_env_variables()
|
private function generate_build_env_variables()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user