Failed to add dockerfile-rails gem

Error upon “fly launch” command as follows:

Error Failed to add dockerfile-rails gem, exiting: exec: “bundle”: cannot run executable found relative to current directory.

This is after adding the db and redis…
Any ideas ?

Can you verify that dockerfile-rails is not in your Gemfile (it should be the last line)?

Assuming it is not there, can you run bundle add dockerfile-rails --optimistic --group development and tell me what you get?

And on the off chance that works, try fly launch again.

dockerfile-rails is indeed not in Gemfile,

Running bundle add dockerfile-rails --optimistic --group development:

Fetching gem metadata from https://rubygems.org/..........
Resolving dependencies...
Fetching gem metadata from https://rubygems.org/..........
Resolving dependencies...
Using rake 13.0.6
Using concurrent-ruby 1.1.10
Using minitest 5.17.0
Using builder 3.2.4
Using websocket-extensions 0.1.5
Using racc 1.6.2
Using date 3.3.3
Using rack 2.2.6.2
Using public_suffix 5.0.1
Using marcel 1.0.2
Using erubi 1.12.0
Using bcrypt 3.1.18
Using crass 1.0.6
Using timeout 0.3.1
Using bundler 2.3.26
Using matrix 0.4.2
Using orm_adapter 0.5.0
Using regexp_parser 2.6.1
Using thor 1.2.1
Using execjs 2.8.1
Using zeitwerk 2.6.6
Using ffi 1.15.5
Using pg 1.4.5
Using redis 4.8.0
Using rexml 3.2.5
Using rubyzip 2.3.2
Using io-console 0.6.0
Using tilt 2.0.11
Using i18n 1.12.0
Using tzinfo 2.0.5
Using websocket-driver 0.7.5
Using nokogiri 1.14.0 (arm64-darwin)
Using rack-test 2.0.2
Using dotenv 2.8.1
Using warden 1.2.9
Using websocket 1.2.9
Using addressable 2.8.1
Using method_source 1.0.0
Using ethon 0.16.0
Using sassc 2.4.0
Using activesupport 7.0.4.1
Using loofah 2.19.1
Using xpath 3.2.0
Using reline 0.3.2
Using selenium-webdriver 4.7.1
Using autoprefixer-rails 10.4.7.0
Using msgpack 1.6.0
Using rails-dom-testing 2.0.3
Using activemodel 7.0.4.1
Using irb 1.6.2
Using typhoeus 1.4.0
Using font-awesome-sass 6.2.1
Using globalid 1.0.1
Using activerecord 7.0.4.1
Using bootsnap 1.15.0
Using nio4r 2.5.8
Using sprockets 4.2.0
Using finnhub_ruby 1.1.18
Using debug 1.7.1
Using activejob 7.0.4.1
Using bindex 0.8.1
Using puma 5.6.5
Using mini_mime 1.1.2
Using net-protocol 0.2.1
Using webdrivers 5.2.0
Using net-imap 0.3.4
Using net-pop 0.1.2
Using net-smtp 0.3.3
Using rails-html-sanitizer 1.4.4
Using mail 2.8.0.1
Using capybara 3.38.0
Using actionview 7.0.4.1
Using actionpack 7.0.4.1
Using jbuilder 2.11.5
Using actioncable 7.0.4.1
Using activestorage 7.0.4.1
Using actionmailer 7.0.4.1
Using railties 7.0.4.1
Using sprockets-rails 3.4.2
Using responders 3.0.1
Using jquery-rails 4.5.1
Using jsbundling-rails 1.1.1
Using turbo-rails 1.3.2
Using web-console 4.2.0
Using actionmailbox 7.0.4.1
Using devise 4.8.1
Using sassc-rails 2.1.2
Using actiontext 7.0.4.1
Using dotenv-rails 2.8.1
Using stimulus-rails 1.2.1
Using rails 7.0.4.1
Fetching dockerfile-rails 1.0.9
Using simple_form 5.1.0 from https://github.com/heartcombo/simple_form.git (at main@ad1bb2e)
Installing dockerfile-rails 1.0.9

fly launch
SUCCESS!
Thanks a lot !!