packtdev / packt-auth
packt-auth
Installs: 24 134
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 1
Open Issues: 0
Requires
- php: ^7.4|^8.0
- doctrine/dbal: *
- illuminate/contracts: ^8.0|^9.0
- laravel/socialite: ^5.1
- socialiteproviders/microsoft-azure: ^4.2
- spatie/laravel-package-tools: ^1.1
Requires (Dev)
- orchestra/testbench: ^6.0
- phpunit/phpunit: ^9.3
- spatie/laravel-ray: ^1.9
This package is auto-updated.
Last update: 2025-03-31 16:27:34 UTC
README
This package defines the basis of O365 login for all Packt Platforms
Installation
You can install the package via composer:
composer require packtdev/packt-auth
Publish and run the required migrations using:
php artisan vendor:publish --provider="Packt\PacktAuth\PacktAuthServiceProvider" --tag="packt-auth-migrations" php artisan migrate
Usage
-
add the PacktAuthTrait to your User Model
-
Update your .env file to include:
AZURE_REDIRECT_URI=
AZURE_CLIENT_ID=
AZURE_CLIENT_SECRET= -
Add
@include('packt-auth::auth.azure')
to your login form -
You can override the default redirect by defining
$authRedirect
in your User model
Changelog
Please see CHANGELOG for more information on what has changed recently.
License
The MIT License (MIT). Please see License File for more information.