diff --git a/.github/workflows/build_container.yml b/.github/workflows/build_container.yml index 493f5ed..1b5df53 100644 --- a/.github/workflows/build_container.yml +++ b/.github/workflows/build_container.yml @@ -44,6 +44,7 @@ jobs: RUBYGEM_PUPPET_METADATA=${{ matrix.rubygem_puppet_metadata }} RUBYGEM_MODULESYNC=${{ matrix.rubygem_modulesync }} RUBYGEM_RUBOCOP_PERFORMANCE=${{ matrix.rubygem_rubocop_performance }} + RUBYGEM_BUNDLER=${{ matrix.rubygem_bundler }} build_arch: linux/amd64,linux/arm64 docker_username: voxpupulibot docker_password: ${{ secrets.DOCKERHUB_BOT_PASSWORD }} diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index d92c91c..3b8970c 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -49,6 +49,7 @@ jobs: RUBYGEM_PUPPET_METADATA=${{ matrix.rubygem_puppet_metadata }} RUBYGEM_OVERCOMMIT=${{ matrix.rubygem_overcommit }} RUBYGEM_MODULESYNC=${{ matrix.rubygem_modulesync }} + RUBYGEM_BUNDLER=${{ matrix.rubygem_bundler }} - name: Login to Docker Hub uses: docker/login-action@v3 diff --git a/Dockerfile b/Dockerfile index 0a7fc83..130ae1a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -41,6 +41,9 @@ ENV RUBYGEM_RA10KE=${RUBYGEM_RA10KE:-3.1.0} ARG RUBYGEM_RUBOCOP_PERFORMANCE ENV RUBYGEM_RUBOCOP_PERFORMANCE=${RUBYGEM_RUBOCOP_PERFORMANCE:-1.21.1} +ARG RUBYGEM_BUNDLER +ENV RUBYGEM_BUNDLER=${RUBYGEM_BUNDLER:-2.5.18} + COPY voxbox/Gemfile / COPY voxbox/Rakefile / COPY Dockerfile / @@ -50,6 +53,9 @@ RUN apk update \ && apk add --no-cache --update alpine-sdk \ && apk add --no-cache --update yamllint \ && apk add --no-cache --update jq \ + && rm -rf /usr/local/lib/ruby/gems/*/gems/bundler-* \ + && rm -rf /usr/local/lib/ruby/gems/*/specifications/default/bundler-*.gemspec \ + && gem install bundler -v ${RUBYGEM_BUNDLER} \ && bundle config set path.system true \ && bundle config set jobs $(nproc) \ && bundle install --gemfile=/Gemfile \ diff --git a/build_versions.json b/build_versions.json index 04f6cfd..a43d248 100644 --- a/build_versions.json +++ b/build_versions.json @@ -13,7 +13,8 @@ "rubygem_modulesync": "3.2.0", "rubygem_r10k": "4.1.0", "rubygem_ra10ke": "3.1.0", - "rubygem_rubocop_performance": "1.21.1" + "rubygem_rubocop_performance": "1.21.1", + "rubygem_bundler": "2.4.22" }, { "puppet_release": 8, @@ -28,7 +29,8 @@ "rubygem_modulesync": "3.2.0", "rubygem_r10k": "4.1.0", "rubygem_ra10ke": "3.1.0", - "rubygem_rubocop_performance": "1.21.1" + "rubygem_rubocop_performance": "1.21.1", + "rubygem_bundler": "2.5.18" } ] }