fix: align install API request structure with backend expectations
Build and Deploy / build (push) Successful in 2m40s
Build and Deploy / deploy (push) Successful in 9s

This commit is contained in:
2026-07-17 06:46:09 +00:00
parent 5652012b2f
commit b697c21f8c
+25 -3
View File
@@ -26,9 +26,31 @@ export default function InstallPage({ onInstall }: Props) {
const config = {
database: dbType === 'sqlite'
? { type: 'sqlite', sqlite: { path: sqlitePath } }
: { type: 'mysql', mysql: { host: mysqlHost, user: mysqlUser, password: mysqlPass, database: mysqlDb } },
redis: { enabled: redisEnabled, host: redisHost, password: redisPass },
? {
type: 'sqlite',
host: 'localhost',
port: 3306,
user: '',
password: '',
database: '',
sqlite: { path: sqlitePath }
}
: {
type: 'mysql',
host: mysqlHost.split(':')[0] || 'localhost',
port: parseInt(mysqlHost.split(':')[1]) || 3306,
user: mysqlUser,
password: mysqlPass,
database: mysqlDb,
sqlite: { path: '' }
},
redis: {
enabled: redisEnabled,
host: redisHost.split(':')[0] || 'localhost',
port: parseInt(redisHost.split(':')[1]) || 6379,
password: redisPass,
db: 0
},
admin: { username: adminUser, password: adminPass }
}