Skip to content
Snippets Groups Projects
Unverified Commit 61b140b1 authored by Andrej Shadura's avatar Andrej Shadura
Browse files

Force Ruby 2.7, as lots of things break with 3.0

parent 5ab0a53b
Branches
Tags
No related merge requests found
This commit is part of merge request !2. Comments created here will be created in the context of that merge request.
...@@ -23,8 +23,8 @@ RUN apt-get update \ ...@@ -23,8 +23,8 @@ RUN apt-get update \
npm \ npm \
patch \ patch \
pkgconf \ pkgconf \
ruby \ ruby2.7 \
ruby-dev \ ruby2.7-dev \
ruby-bundler \ ruby-bundler \
ruby-ffi \ ruby-ffi \
ruby-foreman \ ruby-foreman \
...@@ -45,7 +45,13 @@ RUN apt-get update \ ...@@ -45,7 +45,13 @@ RUN apt-get update \
ADD src/api/Gemfile src/api/Gemfile.lock $INSTALLDIR/src/api/ ADD src/api/Gemfile src/api/Gemfile.lock $INSTALLDIR/src/api/
WORKDIR $INSTALLDIR/src/api/ WORKDIR $INSTALLDIR/src/api/
RUN sed -e '/BUNDLED WITH/,+1 d' Gemfile.lock > Gemfile.lock.new; \ # Force Ruby 2.7 no matter what
RUN for bin in $(dpkg -L ruby | grep /usr/bin/); do \
ln -sf ${bin}2.7 $bin; \
done
RUN echo "ruby '~> 2.7.0'" >> Gemfile
RUN sed -e '/BUNDLED WITH/,+1 d' Gemfile.lock \
-e 's/^ ruby$/ ruby '"$(ruby2.7 -v | cut -d' ' -f2)"'/' > Gemfile.lock.new; \
diff -u Gemfile.lock Gemfile.lock.new; \ diff -u Gemfile.lock Gemfile.lock.new; \
mv Gemfile.lock.new Gemfile.lock mv Gemfile.lock.new Gemfile.lock
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment