Default config files

In an effort to make upgrading the constantly changing config files
easier, Shift defaulted them and merged your true customizations -
where ENV variables may not be used.
This commit is contained in:
Laravel Shift 2021-02-14 02:39:22 +00:00
parent 4a6a5368d3
commit 3e1869f7e6
8 changed files with 115 additions and 86 deletions

View file

@ -12,10 +12,12 @@ return [
| as required, but they're a perfect start for most applications. | as required, but they're a perfect start for most applications.
| |
*/ */
'defaults' => [ 'defaults' => [
'guard' => 'web', 'guard' => 'web',
'passwords' => 'users', 'passwords' => 'users',
], ],
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| Authentication Guards | Authentication Guards
@ -32,16 +34,19 @@ return [
| Supported: "session", "token" | Supported: "session", "token"
| |
*/ */
'guards' => [ 'guards' => [
'web' => [ 'web' => [
'driver' => 'session', 'driver' => 'session',
'provider' => 'users', 'provider' => 'users',
], ],
'api' => [ 'api' => [
'driver' => 'token', 'driver' => 'token',
'provider' => 'users', 'provider' => 'users',
], ],
], ],
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| User Providers | User Providers
@ -58,25 +63,24 @@ return [
| Supported: "database", "eloquent" | Supported: "database", "eloquent"
| |
*/ */
'providers' => [ 'providers' => [
'users' => [ 'users' => [
'driver' => 'eloquent', 'driver' => 'eloquent',
'model' => App\Models\User::class, 'model' => App\User::class,
], ],
// 'users' => [ // 'users' => [
// 'driver' => 'database', // 'driver' => 'database',
// 'table' => 'users', // 'table' => 'users',
// ], // ],
], ],
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| Resetting Passwords | Resetting Passwords
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| |
| Here you may set the options for resetting passwords including the view
| that is your password reset e-mail. You may also set the name of the
| table that maintains all of the reset tokens for your application.
|
| You may specify multiple password reset configurations if you have more | You may specify multiple password reset configurations if you have more
| than one user table or model in the application and you want to have | than one user table or model in the application and you want to have
| separate password reset settings based on the specific user types. | separate password reset settings based on the specific user types.
@ -86,6 +90,7 @@ return [
| they have less time to be guessed. You may change this as needed. | they have less time to be guessed. You may change this as needed.
| |
*/ */
'passwords' => [ 'passwords' => [
'users' => [ 'users' => [
'provider' => 'users', 'provider' => 'users',

View file

@ -15,7 +15,7 @@ return [
| |
*/ */
'default' => env('CACHE_DRIVER', 'database'), 'default' => env('CACHE_DRIVER', 'file'),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
@ -40,13 +40,13 @@ return [
'database' => [ 'database' => [
'driver' => 'database', 'driver' => 'database',
'table' => 'cache', 'table' => 'cache',
'connection' => null, 'connection' => null,
], ],
'file' => [ 'file' => [
'driver' => 'file', 'driver' => 'file',
'path' => storage_path('framework/cache/data'), 'path' => storage_path('framework/cache/data'),
], ],
'memcached' => [ 'memcached' => [
@ -88,7 +88,7 @@ return [
'prefix' => env( 'prefix' => env(
'CACHE_PREFIX', 'CACHE_PREFIX',
'ponyfm_' str_slug(env('APP_NAME', 'laravel'), '_').'_cache'
), ),
]; ];

View file

@ -13,7 +13,7 @@ return [
| |
*/ */
'default' => env('DB_CONNECTION', 'pgsql'), 'default' => env('DB_CONNECTION', 'mysql'),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
@ -34,49 +34,48 @@ return [
'connections' => [ 'connections' => [
'sqlite' => [ 'sqlite' => [
'driver' => 'sqlite', 'driver' => 'sqlite',
'database' => storage_path('database.sqlite'), 'database' => env('DB_DATABASE', database_path('database.sqlite')),
'prefix' => '', 'prefix' => '',
],
'memory' => [
'driver' => 'sqlite',
'database' => ':memory:',
'prefix' => '',
], ],
'mysql' => [ 'mysql' => [
'driver' => 'mysql', 'driver' => 'mysql',
'host' => env('DB_HOST', 'localhost'), 'host' => env('DB_HOST', '127.0.0.1'),
'database' => env('DB_DATABASE', 'forge'), 'port' => env('DB_PORT', '3306'),
'username' => env('DB_USERNAME', 'forge'),
'password' => env('DB_PASSWORD', ''),
'unix_socket' => env('DB_SOCKET', ''),
'charset' => 'utf8mb4',
'collation' => 'utf8mb4_unicode_ci',
'prefix' => '',
'strict' => false,
],
'pgsql' => [
'driver' => 'pgsql',
'host' => env('POSTGRESQL_DB_HOST', 'localhost'),
'database' => env('POSTGRESQL_DB_DATABASE', 'homestead'),
'username' => env('POSTGRESQL_DB_USERNAME', 'homestead'),
'password' => env('POSTGRESQL_DB_PASSWORD', 'secret'),
'charset' => 'utf8',
'prefix' => '',
'schema' => 'public',
],
'sqlsrv' => [
'driver' => 'sqlsrv',
'host' => env('DB_HOST', 'localhost'),
'database' => env('DB_DATABASE', 'forge'), 'database' => env('DB_DATABASE', 'forge'),
'username' => env('DB_USERNAME', 'forge'), 'username' => env('DB_USERNAME', 'forge'),
'password' => env('DB_PASSWORD', ''), 'password' => env('DB_PASSWORD', ''),
'charset' => 'utf8', 'unix_socket' => env('DB_SOCKET', ''),
'prefix' => '', 'charset' => 'utf8mb4',
'collation' => 'utf8mb4_unicode_ci',
'prefix' => '',
'strict' => true,
'engine' => null,
],
'pgsql' => [
'driver' => 'pgsql',
'host' => env('DB_HOST', '127.0.0.1'),
'port' => env('DB_PORT', '5432'),
'database' => env('DB_DATABASE', 'forge'),
'username' => env('DB_USERNAME', 'forge'),
'password' => env('DB_PASSWORD', ''),
'charset' => 'utf8',
'prefix' => '',
'schema' => 'public',
'sslmode' => 'prefer',
],
'sqlsrv' => [
'driver' => 'sqlsrv',
'host' => env('DB_HOST', 'localhost'),
'port' => env('DB_PORT', '1433'),
'database' => env('DB_DATABASE', 'forge'),
'username' => env('DB_USERNAME', 'forge'),
'password' => env('DB_PASSWORD', ''),
'charset' => 'utf8',
'prefix' => '',
], ],
], ],
@ -109,19 +108,11 @@ return [
'client' => 'predis', 'client' => 'predis',
'options' => [ 'default' => [
'cluster' => 'redis', 'host' => env('REDIS_HOST', '127.0.0.1'),
], 'password' => env('REDIS_PASSWORD', null),
'port' => env('REDIS_PORT', 6379),
'clusters' => [ 'database' => 0,
'default' => [
[
'host' => env('REDIS_HOST', '127.0.0.1'),
'password' => env('REDIS_PASSWORD', null),
'port' => env('REDIS_PORT', 6379),
'database' => 0,
],
],
], ],
], ],

View file

@ -13,7 +13,7 @@ return [
| |
*/ */
'default' => env('FILESYSTEM_DRIVER', 'local'), 'default' => env('FILESYSTEM_DRIVER', 'local'),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
@ -37,7 +37,7 @@ return [
| may even configure multiple disks of the same driver. Defaults have | may even configure multiple disks of the same driver. Defaults have
| been setup for each driver as an example of the required options. | been setup for each driver as an example of the required options.
| |
| Supported Drivers: "local", "ftp", "s3", "rackspace" | Supported Drivers: "local", "ftp", "sftp", "s3", "rackspace"
| |
*/ */
@ -45,12 +45,7 @@ return [
'local' => [ 'local' => [
'driver' => 'local', 'driver' => 'local',
'root' => storage_path('app'), 'root' => storage_path('app'),
],
'testing' => [
'driver' => 'local',
'root' => storage_path('app').'/test-files',
], ],
'public' => [ 'public' => [
@ -66,6 +61,7 @@ return [
'secret' => env('AWS_SECRET_ACCESS_KEY'), 'secret' => env('AWS_SECRET_ACCESS_KEY'),
'region' => env('AWS_DEFAULT_REGION'), 'region' => env('AWS_DEFAULT_REGION'),
'bucket' => env('AWS_BUCKET'), 'bucket' => env('AWS_BUCKET'),
'url' => env('AWS_URL'),
], ],
], ],

View file

@ -56,8 +56,8 @@ return [
*/ */
'from' => [ 'from' => [
'address' => env('MAIL_FROM_ADDRESS', 'hello@pony.fm'), 'address' => env('MAIL_FROM_ADDRESS', 'hello@example.com'),
'name' => env('MAIL_FROM_NAME', 'Pony.fm'), 'name' => env('MAIL_FROM_NAME', 'Example'),
], ],
/* /*

View file

@ -4,15 +4,12 @@ return [
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| Default Queue Driver | Default Queue Connection Name
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| |
| The Laravel queue API supports a variety of back-ends via an unified | Laravel's queue API supports an assortment of back-ends via a single
| API, giving you convenient access to each back-end using the same | API, giving you convenient access to each back-end using the same
| syntax for each one. Here you may set the default queue driver. | syntax for every one. Here you may define a default connection.
|
| Supported: "null", "sync", "database", "beanstalkd",
| "sqs", "iron", "redis"
| |
*/ */
@ -27,6 +24,8 @@ return [
| is used by your application. A default configuration has been added | is used by your application. A default configuration has been added
| for each back-end shipped with Laravel. You are free to add more. | for each back-end shipped with Laravel. You are free to add more.
| |
| Drivers: "sync", "database", "beanstalkd", "sqs", "redis", "null"
|
*/ */
'connections' => [ 'connections' => [
@ -35,11 +34,35 @@ return [
'driver' => 'sync', 'driver' => 'sync',
], ],
'database' => [
'driver' => 'database',
'table' => 'jobs',
'queue' => 'default',
'retry_after' => 90,
],
'beanstalkd' => [ 'beanstalkd' => [
'driver' => 'beanstalkd', 'driver' => 'beanstalkd',
'host' => 'localhost', 'host' => 'localhost',
'queue' => 'default', 'queue' => 'default',
'retry_after' => 60, 'retry_after' => 90,
],
'sqs' => [
'driver' => 'sqs',
'key' => env('SQS_KEY', 'your-public-key'),
'secret' => env('SQS_SECRET', 'your-secret-key'),
'prefix' => env('SQS_PREFIX', 'https://sqs.us-east-1.amazonaws.com/your-account-id'),
'queue' => env('SQS_QUEUE', 'your-queue-name'),
'region' => env('SQS_REGION', 'us-east-1'),
],
'redis' => [
'driver' => 'redis',
'connection' => 'default',
'queue' => 'default',
'retry_after' => 90,
'block_for' => null,
], ],
], ],
@ -56,7 +79,8 @@ return [
*/ */
'failed' => [ 'failed' => [
'database' => 'pgsql', 'table' => 'failed_jobs', 'database' => env('DB_CONNECTION', 'mysql'),
'table' => 'failed_jobs',
], ],
]; ];

View file

@ -8,7 +8,7 @@ return [
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| |
| This file is for storing the credentials for third party services such | This file is for storing the credentials for third party services such
| as Stripe, Mailgun, Mandrill, and others. This file provides a sane | as Stripe, Mailgun, SparkPost and others. This file provides a sane
| default location for this type of information, allowing packages | default location for this type of information, allowing packages
| to have a conventional place to find your various credentials. | to have a conventional place to find your various credentials.
| |
@ -22,7 +22,7 @@ return [
'ses' => [ 'ses' => [
'key' => env('SES_KEY'), 'key' => env('SES_KEY'),
'secret' => env('SES_SECRET'), 'secret' => env('SES_SECRET'),
'region' => 'us-east-1', 'region' => env('SES_REGION', 'us-east-1'),
], ],
'sparkpost' => [ 'sparkpost' => [
@ -30,7 +30,7 @@ return [
], ],
'stripe' => [ 'stripe' => [
'model' => App\Models\User::class, 'model' => App\User::class,
'key' => env('STRIPE_KEY'), 'key' => env('STRIPE_KEY'),
'secret' => env('STRIPE_SECRET'), 'secret' => env('STRIPE_SECRET'),
], ],

View file

@ -16,7 +16,7 @@ return [
| |
*/ */
'driver' => env('SESSION_DRIVER', 'database'), 'driver' => env('SESSION_DRIVER', 'file'),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
@ -85,6 +85,19 @@ return [
'table' => 'sessions', 'table' => 'sessions',
/*
|--------------------------------------------------------------------------
| Session Cache Store
|--------------------------------------------------------------------------
|
| When using the "apc" or "memcached" session drivers, you may specify a
| cache store that should be used for these sessions. This value must
| correspond with one of the application's configured cache stores.
|
*/
'store' => null,
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| Session Sweeping Lottery | Session Sweeping Lottery
@ -111,7 +124,7 @@ return [
'cookie' => env( 'cookie' => env(
'SESSION_COOKIE', 'SESSION_COOKIE',
'IfYouAreReadingThisWeWantToWorkWithYou_PleaseDropAnEmailTo_HelloAtPoniverseDotNet' str_slug(env('APP_NAME', 'laravel'), '_').'_session'
), ),
/* /*
@ -151,7 +164,7 @@ return [
| |
*/ */
'secure' => env('SESSION_HTTPS_ONLY', true), 'secure' => env('SESSION_SECURE_COOKIE', false),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------