diff options
author | thecalcaholic <6317548+theCalcaholic@users.noreply.github.com> | 2022-09-28 15:55:17 +0300 |
---|---|---|
committer | thecalcaholic <6317548+theCalcaholic@users.noreply.github.com> | 2022-09-28 17:14:00 +0300 |
commit | 4049a4b07d5009e4e6e23fe8fde2ee29e5fae08f (patch) | |
tree | c1ce1897247b597afffb7b4e5d229962fab9ecbb | |
parent | 412efad20f27c7af17473615d60deefad3bbcdfa (diff) |
90-ncp.cnf.sh: Fix /data-ro being used as db directory outside of installation
Signed-off-by: thecalcaholic <6317548+theCalcaholic@users.noreply.github.com>
-rw-r--r-- | etc/ncp-templates/mysql/90-ncp.cnf.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/etc/ncp-templates/mysql/90-ncp.cnf.sh b/etc/ncp-templates/mysql/90-ncp.cnf.sh index dccb2597..c61fd1bc 100644 --- a/etc/ncp-templates/mysql/90-ncp.cnf.sh +++ b/etc/ncp-templates/mysql/90-ncp.cnf.sh @@ -8,10 +8,10 @@ then echo "INFO: Restoring template to default settings" >&2 DB_DIR=/var/lib/mysql else - if [[ "$DOCKERBUILD" -eq 1 ]] + if is_docker && [[ -f /.ncp-image ]] then echo "INFO: Docker build detected." >&2 - DB_DIR=/data/database + DB_DIR=/data-ro/database elif is_docker then echo "INFO: Docker container detected." >&2 |