From fce186a8e27f300a0689a6e317a2530f0f680ca6 Mon Sep 17 00:00:00 2001 From: Kekskurse Date: Tue, 12 Jan 2021 21:59:49 +0100 Subject: [PATCH] Crons --- app/Console/Kernel.php | 8 ++++++-- docs/setup-server.md | 7 ++++++- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/app/Console/Kernel.php b/app/Console/Kernel.php index 69914e9..94d34be 100644 --- a/app/Console/Kernel.php +++ b/app/Console/Kernel.php @@ -2,6 +2,8 @@ namespace App\Console; +use App\Console\Commands\CalculateSpace; +use App\Console\Commands\CalculateTraffic; use Illuminate\Console\Scheduling\Schedule; use Illuminate\Foundation\Console\Kernel as ConsoleKernel; @@ -13,7 +15,8 @@ class Kernel extends ConsoleKernel * @var array */ protected $commands = [ - // + CalculateSpace::class, + CalculateTraffic::class ]; /** @@ -24,7 +27,8 @@ class Kernel extends ConsoleKernel */ protected function schedule(Schedule $schedule) { - // $schedule->command('inspire')->hourly(); + $schedule->command('calculate:space')->hourlyAt(10)->withoutOverlapping(); + $schedule->command('calculate:traffic')->hourlyAt(10)->withoutOverlapping(); } /** diff --git a/docs/setup-server.md b/docs/setup-server.md index d7ad915..0c9d6b7 100644 --- a/docs/setup-server.md +++ b/docs/setup-server.md @@ -54,10 +54,11 @@ Setup env ``` server { listen 80; - server_name kuvia.cloud www.kuvia.cloud www1.kuvia.cloud www1.kuvia.cloud www2.kuvia.cloud www3.kuvia.cloud www4.kuvia.cloud www5.kuvia.cloud www6.kuvia.cloud www7.kuvia.cloud www8.kuvia.cloud www9.kuvia.cloud; + server_name kuvia.cloud www.kuvia.cloud; root /var/www/kuvia/public; index index.html index.htm index.php; + client_max_body_size 100M; location / { try_files $uri $uri/ /index.php?$query_string; @@ -81,3 +82,7 @@ run ln -s /etc/nginx/sites-available/kuvia /etc/nginx/sites-enabled/ systemctl restart nginx ``` + +# Setup php + +set upload_max_filesize and post_max_size to 100M in php.ini