mirror of
https://gitlab.com/omair-personal/exchange.git
synced 2026-08-19 04:24:08 +00:00
config jwt
This commit is contained in:
@@ -18,3 +18,8 @@ QUEUE_DRIVER=sync
|
||||
REDIS_HOST=127.0.0.1
|
||||
REDIS_PASSWORD=null
|
||||
REDIS_PORT=6379
|
||||
|
||||
JWT_SECRET=JhNAbJXgtxljtjJYaPAtFo160yzKgDTW
|
||||
JWT_TTL=60
|
||||
JWT_REFRESH_TTL=21600
|
||||
JWT_BLACKLIST_GRACE_PERIOD=30
|
||||
@@ -23,9 +23,12 @@ pecl install xdebug && docker-php-ext-enable xdebug
|
||||
|
||||
# Generate an application key. Re-cache.
|
||||
php artisan key:generate
|
||||
php artisan jwt:secret
|
||||
php artisan config:cache
|
||||
php artisan config:clear
|
||||
# php artisan optimize // remove after laravel 5.6
|
||||
|
||||
# Run database migrations with seeder
|
||||
php artisan migrate:refresh --seed
|
||||
|
||||
|
||||
|
||||
@@ -8,6 +8,8 @@ use App\Http\Controllers\Controller;
|
||||
use App\Exceptions\EmailTakenException;
|
||||
use Laravel\Socialite\Facades\Socialite;
|
||||
use Illuminate\Foundation\Auth\AuthenticatesUsers;
|
||||
use Tymon\JWTAuth\Facades\JWTAuth;
|
||||
use Tymon\JWTAuth\Exceptions\JWTException;
|
||||
|
||||
class OAuthController extends Controller
|
||||
{
|
||||
|
||||
@@ -61,5 +61,6 @@ class Kernel extends HttpKernel
|
||||
'ability' => 'App\Http\Middleware\TokenEntrustAbility',
|
||||
'role' => \Zizaco\Entrust\Middleware\EntrustRole::class,
|
||||
'permission' => \Zizaco\Entrust\Middleware\EntrustPermission::class,
|
||||
'jwt' => \App\Http\Middleware\RefreshToken::class
|
||||
];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user