数据库配置
¥Database configuration
Page summary:
/config/database
defines connections, clients, and pooling for supported databases like SQLite, MySQL, and PostgreSQL.
/config/database.js|ts
文件用于定义用于存储应用内容的数据库连接。
¥The /config/database.js|ts
file is used to define database connections that will be used to store the application content.
Strapi 支持以下数据库:
数据库 | 受到推崇的 | 最低限度 |
---|---|---|
MySQL | 8.4 | 8.0 |
玛丽亚数据库 | 11.4 | 10.3 |
PostgreSQL | 17.0 | 14.0 |
SQLite | 3 | 3 |
Strapi 不支持 MongoDB(或任何 NoSQL 数据库),也不支持任何 "云原生" 数据库(例如 Amazon Aurora、Google Cloud SQL 等)。
¥Strapi does not support MongoDB (or any NoSQL databases), nor does it support any "Cloud Native" databases (e.g., Amazon Aurora, Google Cloud SQL, etc.).
¥The following databases are supported by Strapi:
数据库 | 受到推崇的 | 最低限度 |
---|---|---|
MySQL | 8.4 | 8.0 |
玛丽亚数据库 | 11.4 | 10.3 |
PostgreSQL | 17.0 | 14.0 |
SQLite | 3 | 3 |
Strapi 不支持 MongoDB(或任何 NoSQL 数据库),也不支持任何 "云原生" 数据库(例如 Amazon Aurora、Google Cloud SQL 等)。
¥Strapi does not support MongoDB (or any NoSQL databases), nor does it support any "Cloud Native" databases (e.g., Amazon Aurora, Google Cloud SQL, etc.).
Strapi 应用并不意味着连接到预先存在的数据库、不是由 Strapi 应用创建的数据库,也不是连接到 Strapi v3 数据库。Strapi 团队不会支持此类尝试。尝试连接到不受支持的数据库可能并且很可能会导致数据丢失。
¥Strapi applications are not meant to be connected to a pre-existing database, not created by a Strapi application, nor connected to a Strapi v3 database. The Strapi team will not support such attempts. Attempting to connect to an unsupported database may, and most likely will, result in lost data.