-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Changing app basic structure to be more DDD like, added laravel teles…
…cope to monitor app, added sqlite db both for normal and test environment
- Loading branch information
1 parent
2061cd5
commit 6e5f386
Showing
35 changed files
with
413 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...rollers/Auth/ForgotPasswordController.php → ...rollers/Auth/ForgotPasswordController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...Http/Controllers/Auth/LoginController.php → ...Http/Controllers/Auth/LoginController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...p/Controllers/Auth/RegisterController.php → ...p/Controllers/Auth/RegisterController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...trollers/Auth/ResetPasswordController.php → ...trollers/Auth/ResetPasswordController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...ntrollers/Auth/VerificationController.php → ...ntrollers/Auth/VerificationController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
app/Http/Controllers/Controller.php → app/Core/Http/Controllers/Controller.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
app/Http/Middleware/Authenticate.php → app/Core/Http/Middleware/Authenticate.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...tp/Middleware/CheckForMaintenanceMode.php → ...tp/Middleware/CheckForMaintenanceMode.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
app/Http/Middleware/EncryptCookies.php → app/Core/Http/Middleware/EncryptCookies.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...tp/Middleware/RedirectIfAuthenticated.php → ...tp/Middleware/RedirectIfAuthenticated.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
app/Http/Middleware/TrimStrings.php → app/Core/Http/Middleware/TrimStrings.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
app/Http/Middleware/TrustProxies.php → app/Core/Http/Middleware/TrustProxies.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
app/Http/Middleware/VerifyCsrfToken.php → app/Core/Http/Middleware/VerifyCsrfToken.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
app/Providers/AppServiceProvider.php → app/Core/Providers/AppServiceProvider.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
<?php | ||
|
||
namespace App\Providers; | ||
namespace App\Core\Providers; | ||
|
||
use Illuminate\Support\ServiceProvider; | ||
|
||
|
2 changes: 1 addition & 1 deletion
2
app/Providers/AuthServiceProvider.php → app/Core/Providers/AuthServiceProvider.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
app/Providers/BroadcastServiceProvider.php → ...re/Providers/BroadcastServiceProvider.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
app/Providers/EventServiceProvider.php → app/Core/Providers/EventServiceProvider.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
<?php | ||
|
||
namespace App\Core\Providers; | ||
|
||
use Laravel\Telescope\Telescope; | ||
use Illuminate\Support\Facades\Gate; | ||
use Laravel\Telescope\IncomingEntry; | ||
use Laravel\Telescope\TelescopeApplicationServiceProvider; | ||
|
||
class TelescopeServiceProvider extends TelescopeApplicationServiceProvider | ||
{ | ||
/** | ||
* Register any application services. | ||
* | ||
* @return void | ||
*/ | ||
public function register() | ||
{ | ||
if ($this->app->isLocal()) { | ||
$this->app->register(TelescopeServiceProvider::class); | ||
} | ||
|
||
// Telescope::night(); | ||
|
||
$this->hideSensitiveRequestDetails(); | ||
|
||
Telescope::filter(function (IncomingEntry $entry) { | ||
if ($this->app->isLocal()) { | ||
return true; | ||
} | ||
|
||
return $entry->isReportableException() || | ||
$entry->isFailedJob() || | ||
$entry->isScheduledTask() || | ||
$entry->hasMonitoredTag(); | ||
}); | ||
} | ||
|
||
/** | ||
* Prevent sensitive request details from being logged by Telescope. | ||
* | ||
* @return void | ||
*/ | ||
protected function hideSensitiveRequestDetails() | ||
{ | ||
if ($this->app->isLocal()) { | ||
return; | ||
} | ||
|
||
Telescope::hideRequestParameters(['_token']); | ||
|
||
Telescope::hideRequestHeaders([ | ||
'cookie', | ||
'x-csrf-token', | ||
'x-xsrf-token', | ||
]); | ||
} | ||
|
||
/** | ||
* Register the Telescope gate. | ||
* | ||
* This gate determines who can access Telescope in non-local environments. | ||
* | ||
* @return void | ||
*/ | ||
protected function gate() | ||
{ | ||
Gate::define('viewTelescope', function ($user) { | ||
return in_array($user->email, [ | ||
// | ||
]); | ||
}); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.