From d81b640cb1aa6f7998e1e74aee43a6d393e2707e Mon Sep 17 00:00:00 2001 From: Wildan M Date: Sat, 23 Nov 2024 10:11:12 +0700 Subject: [PATCH] Warn if already exists --- src/executor/runnersub.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/executor/runnersub.js b/src/executor/runnersub.js index 31cd671..1fa2be7 100644 --- a/src/executor/runnersub.js +++ b/src/executor/runnersub.js @@ -90,6 +90,8 @@ export async function runConfigSubdomain(config, domaindata, subdomain, sshExec, name: dbname, type: 'mysql', }); + } else if (!value) { + await writeLog(`$> MySQL is already initialized. To create another database, use "mysql create dbname"`); } break; case 'postgres': @@ -132,6 +134,8 @@ export async function runConfigSubdomain(config, domaindata, subdomain, sshExec, type: 'postgres', } ); + } else if (!value) { + await writeLog(`$> PostgreSQL is already initialized. To create another database, use "postgresql create dbname"`); } break; case 'dns':