diff options
author | nachoparker <nacho@ownyourbits.com> | 2017-07-29 12:12:12 +0300 |
---|---|---|
committer | nachoparker <nacho@ownyourbits.com> | 2017-08-11 00:17:56 +0300 |
commit | 530e3a1e06a7fac91d92b4eada4b121879d4501b (patch) | |
tree | df2cc3cc33236de66ad0b3c7619370cfc24e70fc /etc/nextcloudpi-config.d/nc-nextcloud.sh | |
parent | 558e3a5029ce0fe0a68c724389ddb93b1944f532 (diff) |
randomize database password (fixes)v0.17.18
Diffstat (limited to 'etc/nextcloudpi-config.d/nc-nextcloud.sh')
-rw-r--r-- | etc/nextcloudpi-config.d/nc-nextcloud.sh | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/etc/nextcloudpi-config.d/nc-nextcloud.sh b/etc/nextcloudpi-config.d/nc-nextcloud.sh index fee2a10b..dcaf0317 100644 --- a/etc/nextcloudpi-config.d/nc-nextcloud.sh +++ b/etc/nextcloudpi-config.d/nc-nextcloud.sh @@ -45,7 +45,6 @@ install() { :; } configure() { - local DBPASSWD=$( cat /root/.dbpass ) ## RE-CREATE DATABASE TABLE echo "Starting mariaDB" @@ -62,7 +61,9 @@ configure() done echo "Setting up database..." + # workaround to emulate DROP USER IF EXISTS ..;) + local DBPASSWD=$( grep password /root/.my.cnf | cut -d= -f2 ) mysql -u root -p$DBPASSWD <<EOF DROP DATABASE IF EXISTS nextcloud; CREATE DATABASE nextcloud |