Skip to content

Commit

Permalink
Add Dashboard troubleshooting note to explicitly require the engine (#…
Browse files Browse the repository at this point in the history
…654)

* Add Dashboard troubleshooting note to explicitly require the engine

* Update README.md

* Trim trailing whitespace
  • Loading branch information
bensheldon authored Jul 6, 2022
1 parent b7a7058 commit 1c0a48d
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -370,6 +370,16 @@ GoodJob includes a Dashboard as a mountable `Rails::Engine`.
See more at [Monitor and preserve worked jobs](#monitor-and-preserve-worked-jobs)
**Troubleshooting the Dashboard:** Some applications are unable to autoload the Goodjob Engine. To work around this, explicitly require the Engine at the top of your `config/application.rb` file, immediately after Rails is required and before Bundler requires the Rails' groups.
```ruby
# config/application.rb
require_relative 'boot'
require 'rails/all'
require 'good_job/engine' # <= Add this line
# ...
```
#### API-only Rails applications
API-only Rails applications may not have all of the required Rack middleware for the GoodJob Dashboard to function. To re-add the middlware:
Expand Down

0 comments on commit 1c0a48d

Please sign in to comment.