Skip to content

Latest commit

 

History

History
72 lines (42 loc) · 2.38 KB

README.md

File metadata and controls

72 lines (42 loc) · 2.38 KB

🚀 Application License uses a Serial Number for client side

Scrutinizer Code Quality Build Status Latest Stable Version GitHub license Support me ko-fi

This plugin will run if you install a plugin for an endpoint server please visit here https://github.com/irfaardy/app-license-server

This plugin is used to install the application serial number on the client server

🛠️ Installation with Composer

composer require irfa/app-license-client

You can get Composer here


🛠️ Laravel Setup

Add to config/app.php

'providers' => [
    ....
    Irfa\AppLicenseClient\AppLicenseClientServiceProvider::class,
     ];

Add to config/app.php

'aliases' => [
         ....
        'ALC' => Irfa\AppLicenseClient\Facades\AppLicenseClient::class,

    ],

Publish Vendor

php artisan vendor:publish --tag=app-license-client

Config File

config/irfa/app-license-client.php

Plugin Settings

Tambahkan baris ini di file .env
Add this line to file .env

APP_SERIAL_NUMBER=XXXX-XXXX-XXXX-XXXX
APP_LICENSE_ENDPOINT=https://example.com/check/license

Setting Middleware

Buka file App\Http\Kernel.php
Open file App\Http\Kernel.php
Tambahkan item ini di $routeMiddleware
Add this item in $routeMiddleware

'licenseCheck' => \Irfa\AppLicenseClient\Middleware\AppLicenseChecker::class,

Implementasi di route

Route::middleware('licenseCheck')->get('/example','TestController@index');