diff --git a/build b/build index 9c311608..a7e2405d 100755 --- a/build +++ b/build @@ -65,7 +65,7 @@ while [[ "$#" -gt 0 ]]; do --base_image|-b) BASE_IMAGE="$2"; shift ;; --application|-a) APPLICATION="$2"; shift ;; --yes|-y) YES=1 ;; - --no-cache) NO_CACHE="--no-cache" log "Building without cache" ;; + --no-cache) NO_CACHE=1 ;; --push) PUSH=1 ;; --help|-h) help; exit 0 ;; -*) log "Unknown parameter passed: $1"; help; exit 1 ;; @@ -268,6 +268,13 @@ if [ -z "$BASE_IMAGE" ]; then fi fi +if [ ! -z "$NO_CACHE" ] && [ "$NO_CACHE" != "0" ]; then + NO_CACHE="--no-cache" + log "Building without cache" +else + NO_CACHE="" +fi + # -------------------------------------------------------------------- if [ ! -z "$APPLICATION" ]; then