74 Commits

Author SHA1 Message Date
Taylor Otwell
55738c0c4e add REDIS_PERSISTENT env var
Some checks are pending
Tests / PHP 8.2 (push) Waiting to run
Tests / PHP 8.3 (push) Waiting to run
Tests / PHP 8.4 (push) Waiting to run
2025-02-11 11:57:06 -06:00
Taylor Otwell
2897a49c65 add sqlite options 2024-07-16 09:39:20 -05:00
Dries Vints
087543a48c
Revert collation change (#6372) 2024-03-14 14:51:29 +01:00
Taylor Otwell
79969c99c6 change mariadb default 2024-03-13 11:41:47 -05:00
Jason McCreary
1ee7849389
Add DB_CHARSET + DB_COLLATION (#6355) 2024-03-05 10:36:39 -06:00
Taylor Otwell
f437205a5e slim configuration 2024-02-23 14:35:25 -06:00
Taylor Otwell
96508d43ec wip 2024-02-23 11:53:06 -06:00
Taylor Otwell
428a190050
[11.x] Slim skeleton (#6188)
See: https://github.com/laravel/framework/pull/47309

# Laravel 11 Skeleton Overview

### General Notes

More environment variables have been added to the `.env.example` file. 

The default `QUEUE_CONNECTION` variable value has been updated to `database` instead of `sync`.

The `BROADCAST_DRIVER` and `CACHE_DRIVER` environment variables have been renamed to `BROADCAST_CONNECTION` and `CACHE_STORE`, respectively.

The HTTP Kernel has been removed. Configuration that was previously done in this file can be done in the `bootstrap/app.php` file, including registering / replacing middleware.

The console kernel has been removed. Schedules can be defined in the console “routes” file. Commands generated by `make:command` are automatically loaded and do not require registration. Additional command loading paths can be registered in the `bootstrap/app.php` file.

The exception handler has been removed. Exception handling behavior can be configured in the `bootstrap/app.php` file via `reportable`, `renderable`, `throttle`, and more. Callbacks received by these functions will have their type hints inspected to see if they handle a given exception.

The base HTTP controller no longer extends any other classes (requiring new middleware definition feature). No traits are included by default on the base controller. Authorization can be done using facades, or traits can be added manually.

All middleware has been removed. Configuration of these middleware’s behavior can be done via static methods on the middleware themselves (see framework notes).

The `User` model now utilizes a `casts` method instead of a property. The `HasApiTokens` trait has been removed by default since Sanctum is not installed by default.

All service providers except the `AppServiceProvider` have been removed. Policies are auto-discovered and gates can be registered in `AppServiceProvider`. Likewise, events can be registered in `AppServiceProvider`. Routing behavior is now determined / customized in the `bootstrap/app.php` file.

New `bootstrap/app.php` file can be used to customize core framework behavior like routing, container bindings, middleware, and exception handling.

Sanctum is no longer installed by default (see `install:api`).

Configuration files are not present by default. Can be published by `config:publish` command. Default values are present in the framework and application level configuration now cascades with framework definitions, so only customized values need be present in application level configuration files.

Migration files have been re-dated to be evergreen. The `password_reset_tokens` table migration has been combined into the `users` table migration file. Likewise, the `jobs` table migration has been combined into a single migration with the `failed_jobs` table.

Echo bootstrapping has been removed by default. It is re-inserted by new `install:broadcasting` command.

API and channel routes files are not present by default, can be recreated by `install:api` and `install:broadcasting` respectively.
2023-11-28 14:28:15 -06:00
Taylor Otwell
d70eb3e1d1 wip 2022-04-05 20:53:46 -05:00
Taylor Otwell
f7b982ebdf add encryption configuration 2022-03-29 14:50:24 -05:00
neoteknic
8594815f5e
Add username in config to use with phpredis + ACL (#5851)
Linked to https://github.com/laravel/framework/pull/41683/commits
2022-03-25 10:38:42 -05:00
Anjorin Damilare
b2dbbafab9
[9.x] remove null since default parameter is null (#5779) 2022-01-27 11:50:11 -06:00
Ben Johnson
195a7e0374
Replace schema with search_path in pgsql config (#5726)
Per https://github.com/laravel/framework/pull/35588 , the term "schema" (a namespace) has been corrected to "search_path" (a list of namespaces), where appropriate, throughout the framework.

Accordingly, the `schema` configuration key should be changed to `search_path` to better reflect the fact that it may specify a _list_ of schemata (schemas), and not just a single schema. (In several Laravel versions prior to 9.0, the `schema` key could already specify more than one schema, but this fact was undocumented and non-obvious without examining the implementation carefully.)

As of Laravel 9.0, the `search_path` may specify any number of schemata, in any of the following formats:

'search_path' => 'public',
'search_path' => 'public,laravel',
'search_path' => ['public', '"laravel"', "'foobar'", '$bat'],
'search_path' => '\'public\', "laravel", "\'foobar\'", \'$bat\'',
'search_path' => '"$user", public',

Note that in the last example, the `$user` variable refers to PostgreSQL's special $user variable, as described in the Schema Documentation ( https://www.postgresql.org/docs/current/ddl-schemas.html ).

Note also that Laravel's default `search_path` value, 'public', is not necessarily the best choice for every use case. Developers should consult the "Usage Patterns" section of the aforementioned documentation before deciding how best to set the `search_path`, as it has security implications.
2021-11-16 08:26:41 -06:00
Anton Komarev
195faa16cb Fix types consistency in database config (#5191) 2019-12-25 09:05:29 -06:00
Dries Vints
665dfc4328 [6.0] Use phpredis as default Redis client (#5085)
* Use phpredis as default Redis client

Follow up for https://github.com/laravel/framework/pull/29688

It's best that we already start using `phpredis` as a default to discourage usage of Predis.

* Update database.php
2019-08-22 08:22:14 -05:00
Guilherme Pressutto
ddbbd0e67b Using environment variable to set redis prefix (#5062)
It was the only redis setting that wasn't overridable by an environment variable. It can help if you have multiple instances using the same `APP_NAME`, e.g. a staging instance
2019-07-16 13:38:28 -06:00
Antoni Siek
bf60f7f74f Added support for new redis URL property in config/database.php (#5037)
Regarding laravel/framework#28612
2019-05-30 11:22:45 -05:00
Taylor Otwell
b0e0bdc060 formatting 2019-05-07 07:38:15 -05:00
Mathieu TUDISCO
1086e26b32
Update database config relating to Url addition. 2019-05-07 13:49:22 +02:00
Jordan Hall
159b0e79cd
Additional underscore on redis database prefix 2019-04-08 08:50:48 +01:00
Jordan Hall
e68ff0c66a
Use Str class instead of helper function 2019-04-04 22:18:28 +01:00
Jordan Hall
c8bc79e94e
Prefix redis database connection by default to mitigate multiple sites on the same server potentially sharing the same queued jobs 2019-04-04 15:11:18 +01:00
Taylor Otwell
3001f3c6e2 check if extension loaded 2019-02-28 14:31:42 -06:00
Taylor Otwell
a0f6bcc773 comment out options 2019-02-28 08:34:10 -06:00
Taylor Otwell
64b16c2852 revert to old redis config 2019-02-25 14:32:49 -06:00
Taylor Otwell
ea7fc0b336 update client 2019-02-15 07:51:45 -06:00
Taylor Otwell
df4ecb9c83 change default redis configuration structure 2019-02-14 11:03:41 -06:00
Taylor Otwell
9180f646d3 add env variable for mysql ssl cert 2019-01-17 10:41:23 -06:00
Taylor Otwell
c09519f547 formatting 2018-11-07 19:05:31 -05:00
Matthias Niess
5f7decfff1 introduce sqlite foreign_key_constraints config option
This enables the sqlite `foreign_key_constraints` option that was introduced with laravel/framework#26298 for all new installs.

The env variable DB_FOREIGN_KEYS was added to make it easier to handle this in testing (e.g. via phpunit.xml).
2018-10-30 14:24:12 +01:00
Laurence Ioannou
15dac2a961
Update database.php 2018-10-02 14:23:47 +10:00
Barry vd. Heuvel
c3b99e971c Use seperate cache DB for Redis 2018-05-23 21:50:25 +02:00
Frederik Sauer
bdca9d4781 Added port to sqlsrv settings
Most installations won't work without it.
2017-05-03 23:55:48 +02:00
Hélio
94b39dc576 Fix the commit for pass StyleCI 2017-05-03 13:22:10 -03:00
Hélio
e26bd3ffb0 Add sqlsrv as group connection
Since the doc says that the Laravel supports SQL Server out of the box, makes sense add it, out of the box.
2017-05-03 13:20:25 -03:00
Brent Shaffer
a812983d0b Adds socket to config/database.php for consistency
For the mysql driver only (as this only applies to mysql) add the "socket" configuration parameter and corresponding environment variable.
2017-03-15 17:23:34 -07:00
Taylor Otwell
770c41552f Remove fetch mode option. 2017-01-02 17:18:35 -06:00
Graham Campbell
36875bb98e Merge branch 'master' into develop 2016-12-29 13:03:32 +00:00
Taylor Otwell
45b779f807 cluster option not needed anymore 2016-12-12 16:05:32 -06:00
Damien Criado
7d4115f0ca Fix AUTH failed: ERR Client sent AUTH 2016-12-06 01:01:43 +01:00
Taylor Otwell
c803ff1caa revert broken PR 2016-11-16 15:15:29 -06:00
Taylor Otwell
8182b99112 Applied fixes from StyleCI 2016-11-16 20:57:24 +00:00
Loki Else
69df2ada11 Support predis v1.1.1
fix: `AUTH failed: ERR Client sent AUTH, but no password is set [tcp://127.0.0.1:6379]`

According to predix release log: https://github.com/nrk/predis/releases/tag/v1.1.1
2016-11-16 17:17:52 +08:00
Diogo Azevedo
9ca8ed9960 Update the default redis host 2016-11-14 23:44:01 -02:00
Roberto Aguilar
fd42e10a5f Changes localhost to 127.0.0.1 in database config
In https://github.com/laravel/laravel/pull/3641 was decided to use `127.0.0.1` instead of `localhost` to avoid DNS lookups

This change is to maintain consistency between `.env` and `database.php`
2016-11-14 15:19:31 -06:00
Taylor Otwell
9d01389ce3 use utf8mb4 as default character set 2016-10-24 16:07:22 -05:00
Taylor Otwell
d880fb5f85 no need for env 2016-09-22 12:26:13 -05:00
Till Krüss
54ee465deb Added database.redis.client configuration 2016-09-21 13:34:46 -07:00
vlakoff
07c95968b7 Use proper PDO fetch style 2016-06-19 05:16:51 +02:00
Jorge González
8fc0df14bb Add "sslmode" setting for PostgreSQL connection
The commit 586bffa1d7 added support for sslmode in PostgresConnector.php and sslmode has been around since postgres version 9.1 (2011). 

This change makes it possible to specify sslmode from the config file.

Also serves as documentation to other developers so they don't have to
dive deep into the code to figure out that it's posible to set this option.

The posible values for sslmode are:
    disable, allow, prefer, require, verify-ca, verify-full

The default value is "prefer".

http://www.postgresql.org/docs/9.5/static/libpq-ssl.html#LIBPQ-SSL-PROTECTION
2016-05-12 00:59:15 -05:00