refactor: allow usage of the same variable to disable docker pulls

This commit is contained in:
Jose Diaz-Gonzalez
2018-04-23 06:56:51 -04:00
parent ff7acc44df
commit 8a9efd8f62
3 changed files with 6 additions and 4 deletions

View File

@@ -5,8 +5,8 @@ set -eo pipefail; [[ $DOKKU_TRACE ]] && set -x
plugin-install() {
pull-docker-image() {
declare IMAGE="$1"
if [[ "$POSTGRES_DISABLE_PULL" == "true" ]]; then
echo " ! POSTGRES_DISABLE_PULL environment variable detected. Not running pull command." 1>&2
if [[ "$PLUGIN_DISABLE_PULL" == "true" ]]; then
echo " ! ${PLUGIN_DISABLE_PULL_VARIABLE} environment variable detected. Not running pull command." 1>&2
echo " ! docker pull ${IMAGE}" 1>&2
return
fi