Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: improve database type and version visibility #5884

Merged
merged 14 commits into from
Feb 27, 2024
1 change: 1 addition & 0 deletions .spellcheckwordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -579,6 +579,7 @@ solr
somefile
sql
sqlite
sqlsrv
tyler36 marked this conversation as resolved.
Show resolved Hide resolved
src
ssh
sshd
Expand Down
19 changes: 18 additions & 1 deletion docs/content/users/extend/database-types.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,14 @@

DDEV supports many versions of the MariaDB, MySQL, and PostgreSQL database servers.

The default database type is MariaDB, and the default version is currently 10.11, but you can use MariaDB versions 5.5-10.8 and 10.11, MySQL 5.5-8.0, and Postgres 9-16. (New LTS versions of each of these are typically added soon after release. The very old versions are kept for compatibility with older projects.)
The following database types are supported out of the box:
tyler36 marked this conversation as resolved.
Show resolved Hide resolved

- MariaDB 5.5-10.8 and 10.11
- MySQL 5.5-8.0
- Postgres 9-16

The default database type is MariaDB, and the default version is currently 10.4.
tyler36 marked this conversation as resolved.
Show resolved Hide resolved
New LTS versions of each of these are typically added soon after release. The very old versions are kept for compatibility with older projects.
tyler36 marked this conversation as resolved.
Show resolved Hide resolved

You could set these using the [`ddev config`](../usage/commands.md#config) command like this:

Expand Down Expand Up @@ -46,3 +53,13 @@ Since the existing binary database may not be compatible with changes to your co
- If you change the database type or version in an existing project, the existing database will not be compatible with your change, so you’ll want to use [`ddev export-db`](../usage/commands.md#export-db) to save a dump first.
- When you change database type, destroy the existing database using [`ddev delete --omit-snapshot`](../usage/commands.md#delete) before changing, then after [`ddev start`](../usage/commands.md#start) use [`ddev import-db`](../usage/commands.md#import-db) to import the dump you saved.
- Snapshots are always per database type and database version. So if you have snapshots from MariaDB 10.2 and you switch to MariaDB 10.5, don’t expect to be able to restore the old snapshot.

## Other databases types

Through add-ons, additional database types are also supported.
The following official add-ons are available:

- [ddev/ddev-mongo](https://github.com/ddev/ddev-mongo)
tyler36 marked this conversation as resolved.
Show resolved Hide resolved
- [ddev/ddev-sqlsrv](https://github.com/ddev/ddev-sqlsrv)
tyler36 marked this conversation as resolved.
Show resolved Hide resolved

Use `ddev get --list --all` to see a list of all add-ons, including additional community-supported database types.