summaryrefslogtreecommitdiff
path: root/src/AuthLogServiceProvider.php
diff options
context:
space:
mode:
authorSam Light <samlight1994@gmail.com>2025-04-09 22:42:43 +0100
committerSam Light <samlight1994@gmail.com>2025-04-09 22:42:43 +0100
commit254b5f1abfdec2a051988150d7c36df43f455cc1 (patch)
tree0d0dad0ff54c3a5aa425216e9294c4aa02a32691 /src/AuthLogServiceProvider.php
Initial commit
Diffstat (limited to 'src/AuthLogServiceProvider.php')
-rw-r--r--src/AuthLogServiceProvider.php24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/AuthLogServiceProvider.php b/src/AuthLogServiceProvider.php
new file mode 100644
index 0000000..55cc2c2
--- /dev/null
+++ b/src/AuthLogServiceProvider.php
@@ -0,0 +1,24 @@
+<?php
+
+namespace Lightscale\LaralightAuthLog;
+
+use Illuminate\Support\ServiceProvider;
+
+class AuthLogServiceProvider extends ServiceProvider
+{
+ public function boot(): void
+ {
+ $ns = "laralight-auth-log";
+ $dir = __DIR__;
+ $root = "{$dir}/..";
+
+ $this->publishesMigrations([
+ "{$root}/database/migrations" => database_path('migrations', "{$ns}:migrations"),
+ ]);
+
+ $this->mergeConfigFrom("$root/config/auth_log.php", 'auth_log');
+ $this->publishes([
+ "{$root}/config/access_log.php" => config_path('auth_log.php'),
+ ], "{$ns}:config");
+ }
+}