reynotech / dev-login-laravel
Development-only local account seeder for the Dev Login browser extension
Requires
- php: ^8.2
- illuminate/database: ^12.0 || ^13.0
- illuminate/support: ^12.0 || ^13.0
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
README
Development-only local account seeder for the Dev Login browser extension. The
package only runs when Laravel reports APP_ENV=local. It generates a random
password for each profile, calls the consumer's persistence callback, and writes
an ignored users.local.json fixture with file mode 0600.
Install with composer require --dev reynotech/dev-login-laravel. From the
Laravel project root, run:
vendor/bin/dev-login-seed --config=/path/to/dev-login-config.php --organization=2
The config is a PHP file that returns:
return [ 'output' => '/path/to/frontend/.dev-login/users.local.json', 'profiles' => [ ['id' => 'admin', 'title' => 'Administrator', 'user' => 'admin@example.test'], ], 'persist' => static function (array $profile, string $password, array $options): void { // Create or update a local account using the project's models. // Apply its role and revoke old sessions if the password changed. }, ];
The callback receives each profile, its new password, and CLI options such as
organization. The project owns all model, role, and organization behavior.
Run the command only against disposable local accounts: each run rotates their
passwords. Keep the fixture out of Git and exclude it from production builds.