mirror of
https://github.com/louislam/uptime-kuma.git
synced 2024-11-24 10:26:02 +03:00
create data dir if not exists
This commit is contained in:
parent
3ee13bddd1
commit
b604807cfe
1 changed files with 4 additions and 0 deletions
|
@ -12,6 +12,10 @@ class Database {
|
|||
static sqliteInstance = null;
|
||||
|
||||
static async connect() {
|
||||
if (! fs.existsSync(this.dataDir)) {
|
||||
fs.mkdirSync(this.dataDir, { recursive: true });
|
||||
}
|
||||
|
||||
const acquireConnectionTimeout = 120 * 1000;
|
||||
|
||||
R.setup("sqlite", {
|
||||
|
|
Loading…
Reference in a new issue