diff --git a/.env b/.env index 9ab53a967..9948d4d22 100644 --- a/.env +++ b/.env @@ -17,4 +17,6 @@ _APP_INFLUXDB_PORT=8086 _APP_STATSD_HOST=telegraf _APP_STATSD_PORT=8125 _APP_SMTP_HOST=maildev -_APP_SMTP_PORT=25 \ No newline at end of file +_APP_SMTP_PORT=25 +_APP_FUNCTIONS_TIMEOUT=900 +_APP_FUNCTIONS_CONTAINERS=10 \ No newline at end of file diff --git a/Dockerfile b/Dockerfile index 5fd69f865..2d3eeae80 100755 --- a/Dockerfile +++ b/Dockerfile @@ -92,6 +92,8 @@ ENV TZ=Asia/Tel_Aviv \ _APP_STATSD_PORT=8125 \ _APP_SMTP_HOST=smtp \ _APP_SMTP_PORT=25 \ + _APP_FUNCTIONS_TIMEOUT=900 \ + _APP_FUNCTIONS_CONTAINERS=10 \ _APP_SETUP=self-hosted \ _APP_VERSION=$VERSION #ENV _APP_SMTP_SECURE '' diff --git a/app/controllers/web/console.php b/app/controllers/web/console.php index 1e81c240b..3e54122b3 100644 --- a/app/controllers/web/console.php +++ b/app/controllers/web/console.php @@ -368,6 +368,7 @@ App::get('/console/functions/function') ->setParam('events', Config::getParam('events', [])) ->setParam('fileLimit', App::getEnv('_APP_STORAGE_LIMIT', 0)) ->setParam('fileLimitHuman', Storage::human(App::getEnv('_APP_STORAGE_LIMIT', 0))) + ->setParam('timeout', (int) App::getEnv('_APP_FUNCTIONS_TIMEOUT', 900)) ; $layout diff --git a/app/views/console/functions/function.phtml b/app/views/console/functions/function.phtml index b4e148d8d..3f96eee17 100644 --- a/app/views/console/functions/function.phtml +++ b/app/views/console/functions/function.phtml @@ -2,6 +2,7 @@ $fileLimit = $this->getParam('fileLimit', 0); $fileLimitHuman = $this->getParam('fileLimitHuman', 0); $events = array_keys($this->getParam('events', [])); +$timeout = $this->getParam('timeout', 900); ?>