File tree Expand file tree Collapse file tree 2 files changed +4
-1
lines changed
lib/rails/generators/rails/app/templates Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change 11# syntax = docker/dockerfile:1
22
33# Make sure RUBY_VERSION matches the Ruby version in .ruby-version and Gemfile
4- ARG RUBY_VERSION=<%= Gem.ruby_version %>
4+ ARG RUBY_VERSION=<%= gem_ruby_version %>
55FROM registry.docker.com/library/ruby:$RUBY_VERSION-slim as base
66
77# Rails app lives here
Original file line number Diff line number Diff line change @@ -955,6 +955,9 @@ def test_inclusion_of_ruby_version
955955 assert_file "Gemfile" do |content |
956956 assert_match ( /ruby "#{ Gem ::Version . new ( Gem ::VERSION ) >= Gem ::Version . new ( "3.3.13" ) ? Gem . ruby_version : RUBY_VERSION } "/ , content )
957957 end
958+ assert_file "Dockerfile" do |content |
959+ assert_match ( /ARG RUBY_VERSION=#{ Gem ::Version . new ( Gem ::VERSION ) >= Gem ::Version . new ( "3.3.13" ) ? Gem . ruby_version : RUBY_VERSION } / , content )
960+ end
958961 assert_file ".ruby-version" do |content |
959962 if ENV [ "RBENV_VERSION" ]
960963 assert_match ( /#{ ENV [ "RBENV_VERSION" ] } / , content )
You can’t perform that action at this time.
0 commit comments