From 7f59e9c845d6722b2e26ffa291f7fcd8be95d89b Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Tue, 10 Mar 2020 14:16:02 +0900 Subject: [PATCH] Explicitly set --bindir when isntalling bundle ... so that we can make sure that bundle command is installed in GEM_HOME/bin directory. Change-Id: I1ea78bbd2b7fe22d510e10b0c96c0ed7bdc9f8a3 Closes-Bug: #1866176 (cherry picked from commit 0be086fef570892654e288b086ab175df418fa72) (cherry picked from commit 7d64abe4aaf7ba5c7ebaf33fa41808c9537028bd) --- playbooks/run-beaker-tests.yaml | 7 ++++--- playbooks/run-lint-tests.yaml | 9 +++++---- playbooks/run-syntax-tests.yaml | 7 ++++--- playbooks/run-unit-tests.yaml | 7 ++++--- 4 files changed, 17 insertions(+), 13 deletions(-) diff --git a/playbooks/run-beaker-tests.yaml b/playbooks/run-beaker-tests.yaml index f64a93eae..414177d29 100644 --- a/playbooks/run-beaker-tests.yaml +++ b/playbooks/run-beaker-tests.yaml @@ -48,16 +48,17 @@ fi mkdir .bundled_gems export GEM_HOME=`pwd`/.bundled_gems + export GEM_BIN_DIR=$GEM_HOME/bin if [ -f Gemfile ]; then ruby <&1 + $GEM_BIN_DIR/bundle install --without system_tests --retry 3 + $GEM_BIN_DIR/bundle exec rake lint 2>&1 if [ -f metadata.json ]; then - $GEM_HOME/bin/bundle exec rake metadata_lint 2>&1 + $GEM_BIN_DIR/bundle exec rake metadata_lint 2>&1 fi else gem install rake -n ./.bundled_gems/ --no-ri --no-rdoc --no-user-install diff --git a/playbooks/run-syntax-tests.yaml b/playbooks/run-syntax-tests.yaml index 1037ae37b..4ef2a398f 100644 --- a/playbooks/run-syntax-tests.yaml +++ b/playbooks/run-syntax-tests.yaml @@ -5,14 +5,15 @@ export PUPPET_GEM_VERSION='~> {{ puppet }}' mkdir .bundled_gems export GEM_HOME=`pwd`/.bundled_gems + export GEM_BIN_DIR=$GEM_HOME/bin ruby <