Rake error when attempting to run a docker command

Hi, I’m trying to set up a mastodon instance, but when I run “docker-compose run --rm web rake secret” after running “docker-compose build” … I get an error saying:

“WARNING: Image for service web was built because it did not already exist. To rebuild this image you must use docker-compose build or docker-compose up --build.
rake aborted!
Gem::LoadError: You have already activated rake 13.0.1, but your Gemfile requires rake 13.0.6. Prepending bundle exec to your command may solve this.
/opt/mastodon/config/boot.rb:8:in <top (required)>' /opt/mastodon/config/application.rb:1:in require_relative’
/opt/mastodon/config/application.rb:1:in <top (required)>' /opt/mastodon/Rakefile:4:in <top (required)>’
(See full trace by running task with --trace)”

1 Like

docker-compose run --rm web bundle exec rails secret

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.