Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions app/controllers.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
->param('remove', false, new Boolean(), 'Remove a runtime after execution.', true)
->param('cpus', 1, new FloatValidator(true), 'Container CPU.', true)
->param('memory', 512, new Integer(), 'Container RAM memory.', true)
->param('version', 'v5', new WhiteList(\explode(',', System::getEnv('OPR_EXECUTOR_RUNTIME_VERSIONS', 'v5') ?? 'v5')), 'Runtime Open Runtime version.', true)
->param('version', 'v5', new WhiteList(\explode(',', System::getEnv('OPR_EXECUTOR_RUNTIME_VERSIONS', 'v5'))), 'Runtime Open Runtime version.', true)
->param('restartPolicy', DockerAPI::RESTART_NO, new WhiteList([DockerAPI::RESTART_NO, DockerAPI::RESTART_ALWAYS, DockerAPI::RESTART_ON_FAILURE, DockerAPI::RESTART_UNLESS_STOPPED], true), 'Define restart policy for the runtime once an exit code is returned. Default value is "no". Possible values are "no", "always", "on-failure", "unless-stopped".', true)
->inject('response')
->inject('runner')
Expand Down Expand Up @@ -155,7 +155,7 @@
->param('variables', [], new AnyOf([new Text(65535), new Assoc()], AnyOf::TYPE_MIXED), 'Environment variables passed into runtime.', true)
->param('cpus', 1, new FloatValidator(true), 'Container CPU.', true)
->param('memory', 512, new Integer(true), 'Container RAM memory.', true)
->param('version', 'v5', new WhiteList(\explode(',', System::getEnv('OPR_EXECUTOR_RUNTIME_VERSIONS', 'v5') ?? 'v5')), 'Runtime Open Runtime version.', true)
->param('version', 'v5', new WhiteList(\explode(',', System::getEnv('OPR_EXECUTOR_RUNTIME_VERSIONS', 'v5'))), 'Runtime Open Runtime version.', true)
->param('runtimeEntrypoint', '', new Text(1024, 0), 'Commands to run when creating a container. Maximum of 100 commands are allowed, each 1024 characters long.', true)
->param('logging', true, new Boolean(true), 'Whether executions will be logged.', true)
->param('restartPolicy', DockerAPI::RESTART_NO, new WhiteList([DockerAPI::RESTART_NO, DockerAPI::RESTART_ALWAYS, DockerAPI::RESTART_ON_FAILURE, DockerAPI::RESTART_UNLESS_STOPPED], true), 'Define restart policy once exit code is returned by command. Default value is "no". Possible values are "no", "always", "on-failure", "unless-stopped".', true)
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"utopia-php/console": "0.0.*",
"utopia-php/di": "0.3.*",
"utopia-php/dsn": "0.2.*",
"utopia-php/fetch": "0.4.*",
"utopia-php/fetch": "0.5.*",
"utopia-php/framework": "0.34.*",
"utopia-php/orchestration": "0.19.*",
"utopia-php/preloader": "0.2.*",
Expand Down
84 changes: 30 additions & 54 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion src/Executor/Runner/Docker.php
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,8 @@ public function getLogs(string $runtimeId, int $timeout, Response $response): vo
Console::execute('tail -F ' . $tmpLogging . '/timings.txt', '', $output, $timeout, function (string $timingChunk, mixed $process) use ($tmpLogging, &$logsChunk, &$logsProcess, &$datetime, &$offset, $introOffset): void {
$logsProcess = $process;

if (!\file_exists($tmpLogging . '/logs.txt')) {
$logsPath = $tmpLogging . '/logs.txt';
if (!\file_exists($logsPath)) {
if (!empty($logsProcess)) {
\proc_terminate($logsProcess, 9);
}
Expand Down
2 changes: 1 addition & 1 deletion tests/e2e/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public function call(string $method, string $path = '', array $headers = [], arr
$url = $this->endpoint . $path;

$client = new FetchClient();
$client->setTimeout(60);
$client->setTimeout(60000);

foreach ($this->baseHeaders as $key => $value) {
$client->addHeader($key, $value);
Expand Down