Compare commits
2 commits
aa94914ceb
...
a869c922c8
Author | SHA1 | Date | |
---|---|---|---|
Eric Renfro | a869c922c8 | ||
Eric Renfro | 42937d4597 |
|
@ -2,8 +2,17 @@
|
|||
|
||||
restoreDir=/etc/restore
|
||||
pgsqlDir="$restoreDir/postgresql"
|
||||
scriptDir="$(dirname "$0")"
|
||||
|
||||
function readConfig() {
|
||||
local $config
|
||||
|
||||
if [[ -r "${scriptDir}/../config/postgresql.cfg" ]]; then
|
||||
config="$(readlink -f "${scriptDir}/../config/postgresql.cfg")"
|
||||
else
|
||||
exit 2
|
||||
fi
|
||||
|
||||
while read -r -a vals
|
||||
do
|
||||
[[ "${vals[*]}" =~ ^#.*$ ]] && continue
|
||||
|
@ -11,7 +20,7 @@ function readConfig() {
|
|||
if [[ "${vals[0]}" -ge 10 ]]; then
|
||||
echo "${vals[@]}"
|
||||
fi
|
||||
done < postgresql.cfg
|
||||
done < "$config""
|
||||
}
|
||||
|
||||
function runBackups() {
|
||||
|
|
Loading…
Reference in a new issue