make gems install in global dir and not locally, so I can run the CI suite and not have my gems destroyed

This commit is contained in:
HoneyryderChuck 2018-06-12 14:29:14 +01:00
parent e45b5a246c
commit 17e54cb4f4
2 changed files with 7 additions and 1 deletions

View File

@ -12,6 +12,10 @@ services:
- PARALLEL=1
- CI=1
- JEKYLL_ENV=production
- GEM_HOME=/usr/local/bundle
- BUNDLE_PATH=$GEM_HOME
- BUNDLE_SILENCE_ROOT_WARNING=1
- BUNDLE_APP_CONFIG=$GEM_HOME
image: ruby:alpine
depends_on:
- httpproxy

View File

@ -1,10 +1,12 @@
#!/bin/sh
apk --update add g++ make git bash
export PATH=$GEM_HOME/bin:$BUNDLE_PATH/gems/bin:$PATH
mkdir -p "$GEM_HOME" && chmod 777 "$GEM_HOME"
gem install bundler -v="1.16.1" --no-doc --conservative
cd /home && touch Gemfile.lock && \
rm Gemfile.lock && \
bundle install --quiet --jobs 4 && \
PARALLEL=1 CI=1 bundle exec rake test:ci
bundle exec rake test:ci
RET=$?