summaryrefslogtreecommitdiff
path: root/src/AuthLogServiceProvider.php
blob: 55cc2c2a25c6cb0ba1d65c265dc1b6a09a558ac0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
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");
    }
}