Skip to content

Commit 94a416e

Browse files
committed
resolve shellcheck issues
1 parent a5ef2ad commit 94a416e

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

.circleci/config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ workflows:
281281
jobs:
282282
- shellcheck/check:
283283
name: shellcheck
284-
ignore: SC2086,SC2181
284+
ignore: SC2086,SC2181,SC2124
285285
filters:
286286
tags:
287287
only: /^([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?(?:\+[0-9A-Za-z-]+)?$/

entrypoint.sh

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,16 @@
11
#!/bin/bash
22
set -e
3-
source ${PG_APP_HOME}/functions
3+
4+
# shellcheck source=runtime/functions
5+
source "${PG_APP_HOME}/functions"
46

57
[[ ${DEBUG} == true ]] && set -x
68

79
# allow arguments to be passed to postgres
810
if [[ ${1:0:1} = '-' ]]; then
911
EXTRA_ARGS="$@"
1012
set --
11-
elif [[ ${1} == postgres || ${1} == $(which postgres) ]]; then
13+
elif [[ ${1} == postgres || ${1} == $(command -v postgres) ]]; then
1214
EXTRA_ARGS="${@:2}"
1315
set --
1416
fi
@@ -27,8 +29,8 @@ if [[ -z ${1} ]]; then
2729
configure_postgresql
2830

2931
echo "Starting PostgreSQL ${PG_VERSION}..."
30-
exec start-stop-daemon --start --chuid ${PG_USER}:${PG_USER} \
31-
--exec ${PG_BINDIR}/postgres -- -D ${PG_DATADIR} ${EXTRA_ARGS}
32+
exec start-stop-daemon --start --chuid "${PG_USER}:${PG_USER}" \
33+
--exec "${PG_BINDIR}/postgres" -- -D "${PG_DATADIR}" ${EXTRA_ARGS}
3234
else
3335
exec "$@"
3436
fi

0 commit comments

Comments
 (0)