Skip to content

Commit

Permalink
Fix resurrection addon
Browse files Browse the repository at this point in the history
[Bug Fixes]

* Fix resurrection addon - now correctly connects to bosh and accesses
  database to read resurrection state if present.
  • Loading branch information
dennisjbell committed Oct 19, 2023
1 parent f2653c6 commit 1de376f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions hooks/addon-resurrection~easter
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,12 @@ elif [[ "${GENESIS_USE_CREATE_ENV:=0}" == '1' ]] ; then

else
# Do it the slow way...
ssh_cmd=( "${GENESIS_CALL_BIN}" "${GENESIS_ENV_REF}" "bosh" "-A" "ssh" "-c" )
ssh_cmd=( "${GENESIS_CALL_BIN}" "${GENESIS_ENV_REF}" "bosh" "ssh" "-c" )
fi

describe "Connecting to PostgreSQL database on BOSH director..."
psql="$( "${ssh_cmd[@]}" \
'ps auwwx| grep "/packages/[^ ]*/bin/[p]ostges"' 2>/dev/null \
'ps auwwx| grep "/packages/[^ ]*/bin/[p]ostgres"' 2>/dev/null \
| grep '/var/[^ ]*/bin/postgres' \
| sed -e 's#.*\(/var/[^ ]*/bin\)/postgres.*#\1/psql#' )"

Expand Down

0 comments on commit 1de376f

Please sign in to comment.