aboutsummaryrefslogtreecommitdiffstats
path: root/apps/settings/lib
diff options
context:
space:
mode:
authorFerdinand Thiessen <opensource@fthiessen.de>2024-11-13 02:50:13 +0100
committerFerdinand Thiessen <opensource@fthiessen.de>2024-11-13 02:50:13 +0100
commita3e80e4195ee21e2ab5ba462ad4daa26086779bf (patch)
tree08215ce0521d16a7a1594dbcff4f65ff40dff05a /apps/settings/lib
parent397885adfadaf83434d032a250cb11260c66cad3 (diff)
downloadnextcloud-server-feat/postgres-13-17.tar.gz
nextcloud-server-feat/postgres-13-17.zip
feat: Update supported PostgreSQL versionsfeat/postgres-13-17
12 is now EOL but 17 was released and should be supported and tested. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
Diffstat (limited to 'apps/settings/lib')
-rw-r--r--apps/settings/lib/SetupChecks/SupportedDatabase.php14
1 files changed, 12 insertions, 2 deletions
diff --git a/apps/settings/lib/SetupChecks/SupportedDatabase.php b/apps/settings/lib/SetupChecks/SupportedDatabase.php
index 89f78948305..31b907a825e 100644
--- a/apps/settings/lib/SetupChecks/SupportedDatabase.php
+++ b/apps/settings/lib/SetupChecks/SupportedDatabase.php
@@ -24,6 +24,8 @@ class SupportedDatabase implements ISetupCheck {
private const MAX_MARIADB = '11.4';
private const MIN_MYSQL = '8.0';
private const MAX_MYSQL = '8.4';
+ private const MIN_POSTGRES = '13';
+ private const MAX_POSTGRES = '17';
public function __construct(
private IL10N $l10n,
@@ -98,8 +100,16 @@ class SupportedDatabase implements ISetupCheck {
// we only care about X not X.Y or X.Y.Z differences
[$major, ] = explode('.', $versionlc);
$versionConcern = $major;
- if (version_compare($versionConcern, '12', '<') || version_compare($versionConcern, '16', '>')) {
- return SetupResult::warning($this->l10n->t('PostgreSQL version "%s" detected. PostgreSQL >=12 and <=16 is suggested for best performance, stability and functionality with this version of Nextcloud.', $version));
+ if (version_compare($versionConcern, self::MIN_POSTGRES, '<') || version_compare($versionConcern, self::MAX_POSTGRES, '>')) {
+ return SetupResult::warning(
+ $this->l10n->t(
+ 'PostgreSQL version "%1$s" detected. PostgreSQL >=%2$s and <=%3$s is suggested for best performance, stability and functionality with this version of Nextcloud.',
+ [
+ $version,
+ self::MIN_POSTGRES,
+ self::MAX_POSTGRES,
+ ])
+ );
}
} elseif ($databasePlatform instanceof OraclePlatform) {
$version = 'Oracle';