13.3.0-debian-10-r34 release

This commit is contained in:
Bitnami Bot
2021-06-28 22:05:34 +00:00
parent ea8b3f4e43
commit 118868d7f4
4 changed files with 39 additions and 39 deletions

View File

@@ -1018,17 +1018,17 @@ postgresql_execute_print_output() {
local -r user="${2:-postgres}"
local -r pass="${3:-}"
local opts
read -r -a opts <<< "${@:4}"
read -r -a opts <<<"${@:4}"
local args=("-U" "$user")
[[ -n "$db" ]] && args+=("-d" "$db")
[[ "${#opts[@]}" -gt 0 ]] && args+=( "${opts[@]}" )
[[ "${#opts[@]}" -gt 0 ]] && args+=("${opts[@]}")
# Obtain the command specified via stdin
local sql_cmd
sql_cmd="$(< /dev/stdin)"
sql_cmd="$(</dev/stdin)"
debug "Executing SQL command:\n$sql_cmd"
PGPASSWORD=$pass psql "${args[@]}" <<< "$sql_cmd"
PGPASSWORD=$pass psql "${args[@]}" <<<"$sql_cmd"
}
########################
@@ -1128,22 +1128,22 @@ postgresql_ensure_user_exists() {
shift 1
while [ "$#" -gt 0 ]; do
case "$1" in
-p|--password)
shift
password="${1:?missing password}"
;;
--host)
shift
db_host="${1:?missing database host}"
;;
--port)
shift
db_port="${1:?missing database port}"
;;
*)
echo "Invalid command line flag $1" >&2
return 1
;;
-p | --password)
shift
password="${1:?missing password}"
;;
--host)
shift
db_host="${1:?missing database host}"
;;
--port)
shift
db_port="${1:?missing database port}"
;;
*)
echo "Invalid command line flag $1" >&2
return 1
;;
esac
shift
done
@@ -1215,22 +1215,22 @@ postgresql_ensure_database_exists() {
shift 1
while [ "$#" -gt 0 ]; do
case "$1" in
-u|--user)
shift
user="${1:?missing database user}"
;;
--host)
shift
db_host="${1:?missing database host}"
;;
--port)
shift
db_port="${1:?missing database port}"
;;
*)
echo "Invalid command line flag $1" >&2
return 1
;;
-u | --user)
shift
user="${1:?missing database user}"
;;
--host)
shift
db_host="${1:?missing database host}"
;;
--port)
shift
db_port="${1:?missing database port}"
;;
*)
echo "Invalid command line flag $1" >&2
return 1
;;
esac
shift
done

View File

@@ -473,7 +473,7 @@ EOF
if [[ -f "${REPMGR_MOUNTED_CONF_DIR}/repmgr.conf" ]]; then
# remove from default the overrided keys, and append the desired conf
grep -Fxvf "${REPMGR_CONF_FILE}.tmp" "${REPMGR_MOUNTED_CONF_DIR}/repmgr.conf" | awk -F"=" '{print $1;}' > "${REPMGR_CONF_FILE}.keys" && grep -v -f "${REPMGR_CONF_FILE}.keys" "${REPMGR_CONF_FILE}.tmp" > "$REPMGR_CONF_FILE" && cat "${REPMGR_MOUNTED_CONF_DIR}/repmgr.conf" >> "$REPMGR_CONF_FILE"
grep -v -f "${REPMGR_CONF_FILE}.tmp" "${REPMGR_MOUNTED_CONF_DIR}/repmgr.conf" | awk -F"=" '{print $1;}' > "${REPMGR_CONF_FILE}.keys" && grep -v -f "${REPMGR_CONF_FILE}.keys" "${REPMGR_CONF_FILE}.tmp" > "$REPMGR_CONF_FILE" && cat "${REPMGR_MOUNTED_CONF_DIR}/repmgr.conf" >> "$REPMGR_CONF_FILE"
else
cp "${REPMGR_CONF_FILE}.tmp" "${REPMGR_CONF_FILE}"
fi