Verified Commit c0b26346 authored by FabioWidmer's avatar FabioWidmer
Browse files

Update Laravel to v8.6.5

parent ad296316
...@@ -18,6 +18,7 @@ DB_PASSWORD= ...@@ -18,6 +18,7 @@ DB_PASSWORD=
FILESYSTEM_DRIVER=local FILESYSTEM_DRIVER=local
LOG_CHANNEL=stack LOG_CHANNEL=stack
LOG_DEPRECATIONS_CHANNEL=null
LOG_LEVEL=debug LOG_LEVEL=debug
MAIL_MAILER=smtp MAIL_MAILER=smtp
...@@ -31,7 +32,7 @@ MAIL_FROM_NAME="${APP_NAME}" ...@@ -31,7 +32,7 @@ MAIL_FROM_NAME="${APP_NAME}"
QUEUE_CONNECTION=sync QUEUE_CONNECTION=sync
SANCTUM_STATEFUL_DOMAINS=localhost,127.0.0.1,127.0.0.1:8000,::1 SANCTUM_STATEFUL_DOMAINS=localhost,localhost:3000,127.0.0.1,127.0.0.1:8000,::1
SESSION_DRIVER=file SESSION_DRIVER=file
SESSION_LIFETIME=180 SESSION_LIFETIME=180
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
/storage/*.key /storage/*.key
/vendor /vendor
/.idea /.idea
/.vscode
.DS_Store .DS_Store
Thumbs.db Thumbs.db
# Server | Ablota Store # Ablota Store: Server
Provides an API for the Ablota Store and performs background tasks.
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
namespace App\Exceptions; namespace App\Exceptions;
use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler; use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler;
use Throwable;
class Handler extends ExceptionHandler { class Handler extends ExceptionHandler {
protected $dontReport = [ protected $dontReport = [
...@@ -15,6 +16,8 @@ class Handler extends ExceptionHandler { ...@@ -15,6 +16,8 @@ class Handler extends ExceptionHandler {
]; ];
public function register() { public function register() {
// $this->reportable(function(Throwable $e) {
//
});
} }
} }
...@@ -6,6 +6,7 @@ use Illuminate\Foundation\Http\Middleware\TrimStrings as Middleware; ...@@ -6,6 +6,7 @@ use Illuminate\Foundation\Http\Middleware\TrimStrings as Middleware;
class TrimStrings extends Middleware { class TrimStrings extends Middleware {
protected $except = [ protected $except = [
'current_password',
'password', 'password',
'password_confirmation', 'password_confirmation',
]; ];
......
...@@ -2,10 +2,15 @@ ...@@ -2,10 +2,15 @@
namespace App\Http\Middleware; namespace App\Http\Middleware;
use Fideloper\Proxy\TrustProxies as Middleware; use Illuminate\Http\Middleware\TrustProxies as Middleware;
use Illuminate\Http\Request; use Illuminate\Http\Request;
class TrustProxies extends Middleware { class TrustProxies extends Middleware {
protected $proxies; protected $proxies;
protected $headers = Request::HEADER_X_FORWARDED_ALL; protected $headers =
Request::HEADER_X_FORWARDED_FOR |
Request::HEADER_X_FORWARDED_HOST |
Request::HEADER_X_FORWARDED_PORT |
Request::HEADER_X_FORWARDED_PROTO |
Request::HEADER_X_FORWARDED_AWS_ELB;
} }
...@@ -2,13 +2,12 @@ ...@@ -2,13 +2,12 @@
"require": { "require": {
"php": "^7.3|^8.0", "php": "^7.3|^8.0",
"ext-zip": "*", "ext-zip": "*",
"fideloper/proxy": "^4.4", "ext-json": "*",
"fruitcake/laravel-cors": "^2.0", "fruitcake/laravel-cors": "^2.0",
"guzzlehttp/guzzle": "^7.0.1", "guzzlehttp/guzzle": "^7.0.1",
"laravel/framework": "^8.12", "laravel/framework": "^8.65",
"laravel/sanctum": "^2.7", "laravel/sanctum": "^2.11",
"laravel/tinker": "^2.5", "laravel/tinker": "^2.5"
"ext-json": "*"
}, },
"require-dev": { "require-dev": {
"facade/ignition": "^2.5", "facade/ignition": "^2.5",
...@@ -46,6 +45,9 @@ ...@@ -46,6 +45,9 @@
"Illuminate\\Foundation\\ComposerScripts::postAutoloadDump", "Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
"@php artisan package:discover --ansi" "@php artisan package:discover --ansi"
], ],
"post-update-cmd": [
"@php artisan vendor:publish --tag=laravel-assets --ansi"
],
"post-root-package-install": [ "post-root-package-install": [
"@php -r \"file_exists('.env') || copy('.env.example', '.env');\"" "@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
], ],
......
This diff is collapsed.
...@@ -185,6 +185,7 @@ return [ ...@@ -185,6 +185,7 @@ return [
'Config' => Illuminate\Support\Facades\Config::class, 'Config' => Illuminate\Support\Facades\Config::class,
'Cookie' => Illuminate\Support\Facades\Cookie::class, 'Cookie' => Illuminate\Support\Facades\Cookie::class,
'Crypt' => Illuminate\Support\Facades\Crypt::class, 'Crypt' => Illuminate\Support\Facades\Crypt::class,
'Date' => Illuminate\Support\Facades\Date::class,
'DB' => Illuminate\Support\Facades\DB::class, 'DB' => Illuminate\Support\Facades\DB::class,
'Eloquent' => Illuminate\Database\Eloquent\Model::class, 'Eloquent' => Illuminate\Database\Eloquent\Model::class,
'Event' => Illuminate\Support\Facades\Event::class, 'Event' => Illuminate\Support\Facades\Event::class,
...@@ -198,8 +199,9 @@ return [ ...@@ -198,8 +199,9 @@ return [
'Notification' => Illuminate\Support\Facades\Notification::class, 'Notification' => Illuminate\Support\Facades\Notification::class,
'Password' => Illuminate\Support\Facades\Password::class, 'Password' => Illuminate\Support\Facades\Password::class,
'Queue' => Illuminate\Support\Facades\Queue::class, 'Queue' => Illuminate\Support\Facades\Queue::class,
'RateLimiter' => Illuminate\Support\Facades\RateLimiter::class,
'Redirect' => Illuminate\Support\Facades\Redirect::class, 'Redirect' => Illuminate\Support\Facades\Redirect::class,
'Redis' => Illuminate\Support\Facades\Redis::class, // 'Redis' => Illuminate\Support\Facades\Redis::class,
'Request' => Illuminate\Support\Facades\Request::class, 'Request' => Illuminate\Support\Facades\Request::class,
'Response' => Illuminate\Support\Facades\Response::class, 'Response' => Illuminate\Support\Facades\Response::class,
'Route' => Illuminate\Support\Facades\Route::class, 'Route' => Illuminate\Support\Facades\Route::class,
......
...@@ -29,7 +29,7 @@ return [ ...@@ -29,7 +29,7 @@ return [
| users are actually retrieved out of your database or other storage | users are actually retrieved out of your database or other storage
| mechanisms used by this application to persist your user's data. | mechanisms used by this application to persist your user's data.
| |
| Supported: "session", "token" | Supported: "session"
| |
*/ */
'guards' => [ 'guards' => [
...@@ -37,11 +37,6 @@ return [ ...@@ -37,11 +37,6 @@ return [
'driver' => 'session', 'driver' => 'session',
'provider' => 'customers', 'provider' => 'customers',
], ],
'api' => [
'driver' => 'token',
'provider' => 'customers',
'hash' => false,
],
], ],
/* /*
......
...@@ -10,7 +10,7 @@ return [ ...@@ -10,7 +10,7 @@ return [
| framework when an event needs to be broadcast. You may set this to | framework when an event needs to be broadcast. You may set this to
| any of the connections defined in the "connections" array below. | any of the connections defined in the "connections" array below.
| |
| Supported: "pusher", "redis", "log", "null" | Supported: "pusher", "ably", "redis", "log", "null"
| |
*/ */
'default' => env('BROADCAST_DRIVER', 'null'), 'default' => env('BROADCAST_DRIVER', 'null'),
...@@ -36,6 +36,10 @@ return [ ...@@ -36,6 +36,10 @@ return [
'useTLS' => true, 'useTLS' => true,
], ],
], ],
'ably' => [
'driver' => 'ably',
'key' => env('ABLY_KEY'),
],
'redis' => [ 'redis' => [
'driver' => 'redis', 'driver' => 'redis',
'connection' => 'default', 'connection' => 'default',
......
...@@ -12,9 +12,9 @@ return [ ...@@ -12,9 +12,9 @@ return [
| using this caching library. This connection is used when another is | using this caching library. This connection is used when another is
| not explicitly specified when executing a given caching function. | not explicitly specified when executing a given caching function.
| |
| Supported: "apc", "array", "database", "file", | Supported drivers: "apc", "array", "database", "file",
| "memcached", "redis", "dynamodb" | "memcached", "redis", "dynamodb", "octane", "null"
| |
*/ */
'default' => env('CACHE_DRIVER', 'file'), 'default' => env('CACHE_DRIVER', 'file'),
...@@ -40,6 +40,7 @@ return [ ...@@ -40,6 +40,7 @@ return [
'driver' => 'database', 'driver' => 'database',
'table' => 'cache', 'table' => 'cache',
'connection' => null, 'connection' => null,
'lock_connection' => 'default',
], ],
'file' => [ 'file' => [
'driver' => 'file', 'driver' => 'file',
...@@ -66,6 +67,7 @@ return [ ...@@ -66,6 +67,7 @@ return [
'redis' => [ 'redis' => [
'driver' => 'redis', 'driver' => 'redis',
'connection' => 'cache', 'connection' => 'cache',
'lock_connection' => 'default',
], ],
'dynamodb' => [ 'dynamodb' => [
'driver' => 'dynamodb', 'driver' => 'dynamodb',
...@@ -75,6 +77,9 @@ return [ ...@@ -75,6 +77,9 @@ return [
'table' => env('DYNAMODB_CACHE_TABLE', 'cache'), 'table' => env('DYNAMODB_CACHE_TABLE', 'cache'),
'endpoint' => env('DYNAMODB_ENDPOINT'), 'endpoint' => env('DYNAMODB_ENDPOINT'),
], ],
'octane' => [
'driver' => 'octane',
],
], ],
/* /*
......
...@@ -13,7 +13,7 @@ return [ ...@@ -13,7 +13,7 @@ return [
| To learn more: https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS | To learn more: https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS
| |
*/ */
'paths' => ['v1/*'], 'paths' => ['v1/*', 'sanctum/csrf-cookie'],
'allowed_methods' => ['*'], 'allowed_methods' => ['*'],
'allowed_origins' => ['*'], 'allowed_origins' => ['*'],
'allowed_origins_patterns' => [], 'allowed_origins_patterns' => [],
......
...@@ -13,18 +13,6 @@ return [ ...@@ -13,18 +13,6 @@ return [
*/ */
'default' => env('FILESYSTEM_DRIVER', 'local'), 'default' => env('FILESYSTEM_DRIVER', 'local'),
/*
|--------------------------------------------------------------------------
| Default Cloud Filesystem Disk
|--------------------------------------------------------------------------
|
| Many applications store files both locally and in the cloud. For this
| reason, you may specify a default "cloud" driver here. This driver
| will be bound as the Cloud disk implementation in the container.
|
*/
'cloud' => env('FILESYSTEM_CLOUD', 's3'),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| Filesystem Disks | Filesystem Disks
...@@ -56,6 +44,7 @@ return [ ...@@ -56,6 +44,7 @@ return [
'bucket' => env('AWS_BUCKET'), 'bucket' => env('AWS_BUCKET'),
'url' => env('AWS_URL'), 'url' => env('AWS_URL'),
'endpoint' => env('AWS_ENDPOINT'), 'endpoint' => env('AWS_ENDPOINT'),
'use_path_style_endpoint' => env('AWS_USE_PATH_STYLE_ENDPOINT', false),
], ],
], ],
......
...@@ -17,6 +17,18 @@ return [ ...@@ -17,6 +17,18 @@ return [
*/ */
'default' => env('LOG_CHANNEL', 'stack'), 'default' => env('LOG_CHANNEL', 'stack'),
/*
|--------------------------------------------------------------------------
| Deprecations Log Channel
|--------------------------------------------------------------------------
|
| This option controls the log channel that should be used to log warnings
| regarding deprecated PHP and library features. This allows you to get
| your application ready for upcoming major versions of dependencies.
|
*/
'deprecations' => env('LOG_DEPRECATIONS_CHANNEL', 'null'),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| Log Channels | Log Channels
...@@ -66,6 +78,7 @@ return [ ...@@ -66,6 +78,7 @@ return [
], ],
'stderr' => [ 'stderr' => [
'driver' => 'monolog', 'driver' => 'monolog',
'level' => env('LOG_LEVEL', 'debug'),
'handler' => StreamHandler::class, 'handler' => StreamHandler::class,
'formatter' => env('LOG_STDERR_FORMATTER'), 'formatter' => env('LOG_STDERR_FORMATTER'),
'with' => [ 'with' => [
......
...@@ -27,7 +27,7 @@ return [ ...@@ -27,7 +27,7 @@ return [
| mailers below. You are free to add additional mailers as required. | mailers below. You are free to add additional mailers as required.
| |
| Supported: "smtp", "sendmail", "mailgun", "ses", | Supported: "smtp", "sendmail", "mailgun", "ses",
| "postmark", "log", "array" | "postmark", "log", "array", "failover"
| |
*/ */
'mailers' => [ 'mailers' => [
...@@ -61,6 +61,13 @@ return [ ...@@ -61,6 +61,13 @@ return [
'array' => [ 'array' => [
'transport' => 'array', 'transport' => 'array',
], ],
'failover' => [
'transport' => 'failover',
'mailers' => [
'smtp',
'log',
],
],
], ],
/* /*
......
...@@ -34,6 +34,7 @@ return [ ...@@ -34,6 +34,7 @@ return [
'table' => 'jobs', 'table' => 'jobs',
'queue' => 'default', 'queue' => 'default',
'retry_after' => 90, 'retry_after' => 90,
'after_commit' => false,
], ],
'beanstalkd' => [ 'beanstalkd' => [
'driver' => 'beanstalkd', 'driver' => 'beanstalkd',
...@@ -41,15 +42,17 @@ return [ ...@@ -41,15 +42,17 @@ return [
'queue' => 'default', 'queue' => 'default',
'retry_after' => 90, 'retry_after' => 90,
'block_for' => 0, 'block_for' => 0,
'after_commit' => false,
], ],
'sqs' => [ 'sqs' => [
'driver' => 'sqs', 'driver' => 'sqs',
'key' => env('AWS_ACCESS_KEY_ID'), 'key' => env('AWS_ACCESS_KEY_ID'),
'secret' => env('AWS_SECRET_ACCESS_KEY'), 'secret' => env('AWS_SECRET_ACCESS_KEY'),
'prefix' => env('SQS_PREFIX'), 'prefix' => env('SQS_PREFIX'),
'queue' => env('SQS_QUEUE'), 'queue' => env('SQS_QUEUE', 'default'),
'suffix' => env('SQS_SUFFIX'), 'suffix' => env('SQS_SUFFIX'),
'region' => env('AWS_DEFAULT_REGION'), 'region' => env('AWS_DEFAULT_REGION'),
'after_commit' => false,
], ],
'redis' => [ 'redis' => [
'driver' => 'redis', 'driver' => 'redis',
...@@ -57,6 +60,7 @@ return [ ...@@ -57,6 +60,7 @@ return [
'queue' => env('REDIS_QUEUE', 'default'), 'queue' => env('REDIS_QUEUE', 'default'),
'retry_after' => 90, 'retry_after' => 90,
'block_for' => null, 'block_for' => null,
'after_commit' => false,
], ],
], ],
......
...@@ -11,7 +11,17 @@ return [ ...@@ -11,7 +11,17 @@ return [
| and production domains which access your API via a frontend SPA. | and production domains which access your API via a frontend SPA.
| |
*/ */
'stateful' => explode(',', env('SANCTUM_STATEFUL_DOMAINS', 'localhost,127.0.0.1,127.0.0.1:8000,::1')), 'stateful' => explode(
',',
env(
'SANCTUM_STATEFUL_DOMAINS',
sprintf(
'%s%s',
'localhost,localhost:3000,127.0.0.1,127.0.0.1:8000,::1',
env('APP_URL') ? ',' . parse_url(env('APP_URL'), PHP_URL_HOST) : ''
)
)
),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
......
...@@ -151,7 +151,7 @@ return [ ...@@ -151,7 +151,7 @@ return [
| |
| By setting this option to true, session cookies will only be sent back | By setting this option to true, session cookies will only be sent back
| to the server if the browser has a HTTPS connection. This will keep | to the server if the browser has a HTTPS connection. This will keep
| the cookie from being sent to you if it can not be done securely. | the cookie from being sent to you when it can't be done securely.
| |
*/ */
'secure' => env('SESSION_SECURE_COOKIE'), 'secure' => env('SESSION_SECURE_COOKIE'),
......
*.sqlite *.sqlite*
*.sqlite-journal
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment