Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/vm.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/static
diff options
context:
space:
mode:
authorDaniel Hansson <mailto@danielhansson.nu>2022-05-03 20:25:49 +0300
committerGitHub <noreply@github.com>2022-05-03 20:25:49 +0300
commitd97736c616d2eb41da870cb506d4e2b2b8563473 (patch)
tree1748d3b17a5f0e3f2507151431b9c8e00bdc3d08 /static
parentc4b764acbd4fb3c66acb24cddfe21774a1363126 (diff)
Ubuntu 22.04 (#2279)
Signed-off-by: enoch85 <github@hanssonit.se>
Diffstat (limited to 'static')
-rw-r--r--static/change_db_pass.sh8
1 files changed, 4 insertions, 4 deletions
diff --git a/static/change_db_pass.sh b/static/change_db_pass.sh
index 75d39e0e..d82f4b0e 100644
--- a/static/change_db_pass.sh
+++ b/static/change_db_pass.sh
@@ -5,7 +5,7 @@ SCRIPT_NAME="Change Database Password"
source /var/scripts/fetch_lib.sh || source <(curl -sL https://raw.githubusercontent.com/nextcloud/vm/master/lib.sh)
# Get all needed variables from the library
-ncdbpass
+ncdb
# T&M Hansson IT AB © - 2022, https://www.hanssonit.se/
@@ -19,12 +19,12 @@ debug_mode
cd /tmp
sudo -u www-data php "$NCPATH"/occ config:system:set dbpassword --value="$NEWPGPASS"
-if [ "$(sudo -u postgres psql -c "ALTER USER $NCUSER WITH PASSWORD '$NEWPGPASS'";)" == "ALTER ROLE" ]
+if [ "$(sudo -u postgres psql -c "ALTER USER $PGDB_USER WITH PASSWORD '$NEWPGPASS'";)" == "ALTER ROLE" ]
then
sleep 1
else
print_text_in_color "$IRed" "Changing PostgreSQL Nextcloud password failed."
- sed -i "s| 'dbpassword' =>.*| 'dbpassword' => '$NCCONFIGDBPASS',|g" /var/www/nextcloud/config/config.php
- print_text_in_color "$IRed" "Nothing is changed. Your old password is: $NCCONFIGDBPASS"
+ sed -i "s| 'dbpassword' =>.*| 'dbpassword' => '$NCDBPASS',|g" /var/www/nextcloud/config/config.php
+ print_text_in_color "$IRed" "Nothing is changed. Your old password is: $NCDBPASS"
exit 1
fi