Making Laravel Passport work with Lumen

Copy from https://github.com/dusterio/lumen-passport and https://github.com/dusterio/lumen-passport/issues/136 You need to create a config file for auth services as config/auth.php: <?php return [ ‘defaults’ => [ ‘guard’ => ‘api’, ‘passwords’ => ‘users’, ], ‘guards’ => [ ‘api’ => [ ‘driver’ => ‘passport’, ‘provider’ => ‘users’, ], ], ‘providers’ => [ ‘users’ => [ ‘driver’ => ‘eloquent’, ‘model’ => \App\User::classContinue reading “Making Laravel Passport work with Lumen”

proc_open(): fork failed – Cannot allocate memory

As composer troubleshooting guide here This could be happening because the VPS runs out of memory and has no Swap space enabled. free -m To enable the swap you can use for example: sudo /bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=1024 sudo /sbin/mkswap /var/swap.1 sudo /sbin/swapon /var/swap.1       https://stackoverflow.com/questions/18116261/php-composer-update-cannot-allocate-memory-error-using-laravel-4

Laravel 5 – Remove public from URL

By: KA_lin Renaming the server.php to index.php (no modifications) Copy the .htaccess from public (like rimon.ekjon said below) Changing .htaccess it a bit as follows for statics: RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)/$ /$1 [L,R=301] RewriteCond %{REQUEST_URI} !(\.css|\.js|\.png|\.jpg|\.gif|robots\.txt)$ [NC] RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^ index.php [L] RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-fContinue reading “Laravel 5 – Remove public from URL”