Skip to content

Commit 62afd94

Browse files
jaapmarcusKristan Kenney
authored andcommitted
Port missing postgesql connection
+ Fixed missing '
1 parent 54062bf commit 62afd94

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

bin/v-add-database-host

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ case $type in
9999
pgsql) str="HOST='$host' USER='$dbuser' PASSWORD='$dbpass'";
100100
str="$str CHARSETS='$charsets' TPL='$template' MAX_DB='$max_db'";
101101
str="$str U_SYS_USERS='' U_DB_BASES='0' SUSPENDED='no'";
102-
str="$str TIME='$time' DATE='$date' PORT='$port";;
102+
str="$str TIME='$time' DATE='$date' PORT='$port'";;
103103
esac
104104

105105

func/db.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,8 +109,8 @@ psql_connect() {
109109
log_event "$E_PARSING" "$ARGUMENTS"
110110
exit $E_PARSING
111111
fi
112-
113-
psql -h $HOST -U $USER -c "SELECT VERSION()" > /dev/null 2>/tmp/e.psql
112+
113+
psql -h $HOST -U $USER -p $PORT -c "SELECT VERSION()" > /dev/null 2>/tmp/e.psql
114114
if [ '0' -ne "$?" ]; then
115115
if [ "$notify" != 'no' ]; then
116116
echo -e "Can't connect to PostgreSQL $HOST\n$(cat /tmp/e.psql)" |\

0 commit comments

Comments
 (0)