Config on redmine server (docker image -> redmine:4.0.3-passenger)
1. add prefix uri to end of file config/environment.rb
Redmine::Utils::relative_url_root = '/redmine/'
 
2. add scope to file routes.rb
   Rails.application.routes.draw do
   scope 'redmine' do
     ...
   end
   end
3. create link file
cd redmine/public ln -s . redmine
application_helper.rb
def thumbnail_tag(attachment)
    thumbnail_size = Setting.thumbnails_size.to_i
    src = thumbnail_path(attachment)
    src['/redmine'] = ''
#end
    link_to(
      image_tag(
         src,#thumbnail_path(attachment),
        :srcset => srcset, # "#{thumbnail_path(attachment, :size => thumbnail_size * 2)} 2x",
        :style => style # "max-width: #{thumbnail_size}px; max-height: #{thumbnail_size}px;" 
      ),
      attachment_path(
        attachment
      ),
      :title => attachment.filename
    )
  end
app/views/common/_image.html.erb
<%= path['/redmine'] = '' %>
.... The rest is the same.

