diff --git a/.env.example b/.env.example index 108283ff..85fc8c60 100644 --- a/.env.example +++ b/.env.example @@ -2,7 +2,6 @@ APP_NAME=Laravel APP_ENV=production APP_KEY= APP_DEBUG=false -APP_URL=http://localhost LOG_CHANNEL=daily @@ -12,7 +11,6 @@ SESSION_DRIVER=file SESSION_LIFETIME=120 LDAP_HOST= -LDAP_BASE_DN= LDAP_USERNAME= LDAP_PASSWORD= LDAP_CACHE=false diff --git a/.env.testing b/.env.testing index 24ad79fd..ef55ac0f 100644 --- a/.env.testing +++ b/.env.testing @@ -2,7 +2,6 @@ APP_NAME=Laravel APP_ENV=local APP_KEY= APP_DEBUG=true -APP_URL=http://localhost LOG_CHANNEL=stderr @@ -12,7 +11,6 @@ SESSION_DRIVER=file SESSION_LIFETIME=120 LDAP_HOST=openldap -LDAP_BASE_DN="dc=Test" LDAP_USERNAME="cn=admin,dc=Test" LDAP_PASSWORD="test" LDAP_CACHE=false diff --git a/app/Classes/LDAP/Export.php b/app/Classes/LDAP/Export.php index 1abd1b98..58eb9428 100644 --- a/app/Classes/LDAP/Export.php +++ b/app/Classes/LDAP/Export.php @@ -29,7 +29,7 @@ abstract class Export abstract public function __toString(): string; - protected function header() + protected function header(): string { $output = ''; @@ -42,7 +42,7 @@ abstract class Export //$output .= sprintf('# %s: %s',__('Search Filter'),$this->entry->dn).$this->br; $output .= sprintf('# %s: %s',__('Total Entries'),$this->items->count()).$this->br; $output .= '#'.$this->br; - $output .= sprintf('# %s %s (%s) on %s',__('Generated by'),config('app.name'),config('app.url'),date('F j, Y g:i a')).$this->br; + $output .= sprintf('# %s %s (%s) on %s',__('Generated by'),config('app.name'),request()->root(),date('F j, Y g:i a')).$this->br; $output .= sprintf('# %s %s',__('Exported by'),Auth::user() ?: 'Anonymous').$this->br; $output .= sprintf('# %s: %s',__('Version'),config('app.version')).$this->br; diff --git a/config/app.php b/config/app.php index 538b8cd6..0ebaea3d 100644 --- a/config/app.php +++ b/config/app.php @@ -43,19 +43,6 @@ return [ 'debug' => (bool) env('APP_DEBUG', false), - /* - |-------------------------------------------------------------------------- - | Application URL - |-------------------------------------------------------------------------- - | - | This URL is used by the console to properly generate URLs when using - | the Artisan command line tool. You should set this to the root of - | the application so that it's available within Artisan commands. - | - */ - - 'url' => env('APP_URL', 'http://localhost'), - /* |-------------------------------------------------------------------------- | Application Timezone diff --git a/config/ldap.php b/config/ldap.php index b9da888a..7fd23c7f 100644 --- a/config/ldap.php +++ b/config/ldap.php @@ -35,7 +35,6 @@ return [ 'username' => env('LDAP_USERNAME', 'cn=user,dc=local,dc=com'), 'password' => env('LDAP_PASSWORD', 'secret'), 'port' => env('LDAP_PORT', 389), - 'base_dn' => env('LDAP_BASE_DN', 'dc=local,dc=com'), 'timeout' => env('LDAP_TIMEOUT', 5), 'use_ssl' => env('LDAP_SSL', false), 'use_tls' => env('LDAP_TLS', false), @@ -47,7 +46,6 @@ return [ 'username' => env('LDAP_USERNAME', 'cn=user,dc=local,dc=com'), 'password' => env('LDAP_PASSWORD', 'secret'), 'port' => env('LDAP_PORT', 636), - 'base_dn' => env('LDAP_BASE_DN', 'dc=local,dc=com'), 'timeout' => env('LDAP_TIMEOUT', 5), 'use_ssl' => env('LDAP_SSL', true), 'use_tls' => env('LDAP_TLS', false), @@ -59,7 +57,6 @@ return [ 'username' => env('LDAP_USERNAME', 'cn=user,dc=local,dc=com'), 'password' => env('LDAP_PASSWORD', 'secret'), 'port' => env('LDAP_PORT', 389), - 'base_dn' => env('LDAP_BASE_DN', 'dc=local,dc=com'), 'timeout' => env('LDAP_TIMEOUT', 5), 'use_ssl' => env('LDAP_SSL', false), 'use_tls' => env('LDAP_TLS', true), @@ -72,7 +69,6 @@ return [ 'username' => 'cn=Directory Manager', 'password' => 'password', 'port' => 1389, - 'base_dn' => 'dc=example,dc=com', 'timeout' => env('LDAP_TIMEOUT', 5), 'use_ssl' => env('LDAP_SSL', false), 'use_tls' => env('LDAP_TLS', false),