mirror of
https://github.com/YunoHost-Apps/immich_ynh.git
synced 2024-09-03 20:36:24 +02:00
Fix myynh_update_psql_db
This commit is contained in:
parent
453e4319bd
commit
11652c9915
1 changed files with 2 additions and 2 deletions
|
@ -274,8 +274,8 @@ myynh_create_psql_db() {
|
||||||
myynh_update_psql_db() {
|
myynh_update_psql_db() {
|
||||||
for db in postgres "$app"
|
for db in postgres "$app"
|
||||||
do
|
do
|
||||||
test_collation_mismatch=$(ynh_exec_warn_less myynh_execute_psql_as_root --sql=";" --database="$db" | grep "collation version mismatch")
|
if ynh_exec_warn_less myynh_execute_psql_as_root --sql=";" --database="$db" \
|
||||||
if [ -n "$test_collation_mismatch" ]
|
| grep -q "collation version mismatch"
|
||||||
then
|
then
|
||||||
ynh_exec_warn_less myynh_execute_psql_as_root --sql="REINDEX DATABASE $db;" --database="$db"
|
ynh_exec_warn_less myynh_execute_psql_as_root --sql="REINDEX DATABASE $db;" --database="$db"
|
||||||
myynh_execute_psql_as_root --sql="ALTER DATABASE $db REFRESH COLLATION VERSION;" --database="$db"
|
myynh_execute_psql_as_root --sql="ALTER DATABASE $db REFRESH COLLATION VERSION;" --database="$db"
|
||||||
|
|
Loading…
Reference in a new issue