From d8b9ab926d1582df8c786616cce0f9411ebeb401 Mon Sep 17 00:00:00 2001 From: David Newhall II Date: Mon, 8 Jul 2019 21:00:27 -0700 Subject: [PATCH] fix paths in docker build --- integrations/influxunifi/init/docker/hooks/build | 16 +++++++++------- integrations/influxunifi/init/docker/hooks/push | 6 ++++-- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/integrations/influxunifi/init/docker/hooks/build b/integrations/influxunifi/init/docker/hooks/build index fe37e43a..edfefd2d 100755 --- a/integrations/influxunifi/init/docker/hooks/build +++ b/integrations/influxunifi/init/docker/hooks/build @@ -1,13 +1,13 @@ #!/bin/bash - -# This always run local to the Dockerfile folder, so the path is ../.. - -set -e -o pipefail - # The Docker Cloud config must pass in the BUILDS env variable. # See README.md (in this dir) and the screenshot for more info. -source ../../.metadata.sh +set -e -o pipefail + +# This always run local to the Dockerfile folder, so the path is ../.. +pushd ../.. + +source .metadata.sh # Build each configured image from Docker Cloud. for build in $BUILDS; do @@ -27,5 +27,7 @@ for build in $BUILDS; do --build-arg "VENDOR=${VENDOR}" \ --build-arg "AUTHOR=${MAINT}" \ --tag "${IMAGE_NAME}_${os}_${name}" \ - --file Dockerfile ../.. + --file Dockerfile . done + +popd diff --git a/integrations/influxunifi/init/docker/hooks/push b/integrations/influxunifi/init/docker/hooks/push index c71e906c..f49206ee 100755 --- a/integrations/influxunifi/init/docker/hooks/push +++ b/integrations/influxunifi/init/docker/hooks/push @@ -1,10 +1,12 @@ #!/bin/bash - # This post build hook creates multi-architecture docker manifests. # It's all a bit complicated for some reason. + set -e -o pipefail -source ../../.metadata.sh +pushd ../.. +source .metadata.sh +popd if [ "$BUILDS" != "" ]; then TAGS=$DOCKER_TAG