mirror of
https://github.com/xiaoxinpro/nginx-proxy-manager-zh.git
synced 2025-02-02 09:48:13 -05:00
Merge pull request #1122 from jc21/fixes-some-database-issues
Fixes some database issues on raspberry pi
This commit is contained in:
commit
0e9cd5db9c
@ -95,7 +95,8 @@ async function createDbConfigFromEnvironment() {
|
|||||||
client: 'sqlite3',
|
client: 'sqlite3',
|
||||||
connection: {
|
connection: {
|
||||||
filename: envSqliteFile
|
filename: envSqliteFile
|
||||||
}
|
},
|
||||||
|
useNullAsDefault: true
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
if (JSON.stringify(configData.database) === JSON.stringify(newConfig)) {
|
if (JSON.stringify(configData.database) === JSON.stringify(newConfig)) {
|
||||||
|
@ -122,18 +122,15 @@ services:
|
|||||||
depends_on:
|
depends_on:
|
||||||
- db
|
- db
|
||||||
db:
|
db:
|
||||||
image: ghcr.io/linuxserver/mariadb
|
image: yobasystems/alpine-mariadb:latest
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
environment:
|
environment:
|
||||||
PUID: 1001
|
|
||||||
PGID: 1001
|
|
||||||
TZ: "Europe/London"
|
|
||||||
MYSQL_ROOT_PASSWORD: "changeme"
|
MYSQL_ROOT_PASSWORD: "changeme"
|
||||||
MYSQL_DATABASE: "npm"
|
MYSQL_DATABASE: "npm"
|
||||||
MYSQL_USER: "changeuser"
|
MYSQL_USER: "changeuser"
|
||||||
MYSQL_PASSWORD: "changepass"
|
MYSQL_PASSWORD: "changepass"
|
||||||
volumes:
|
volumes:
|
||||||
- ./data/mariadb:/config
|
- ./data/mariadb:/var/lib/mysql
|
||||||
```
|
```
|
||||||
|
|
||||||
_Please note, that `DB_MYSQL_*` environment variables will take precedent over `DB_SQLITE_*` var>
|
_Please note, that `DB_MYSQL_*` environment variables will take precedent over `DB_SQLITE_*` var>
|
||||||
@ -185,7 +182,8 @@ Here's an example for `sqlite` configuration as it is generated from the environ
|
|||||||
"client": "sqlite3",
|
"client": "sqlite3",
|
||||||
"connection": {
|
"connection": {
|
||||||
"filename": "/data/database.sqlite"
|
"filename": "/data/database.sqlite"
|
||||||
}
|
},
|
||||||
|
"useNullAsDefault": true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user