This add-on is operated by Wrenchmode
A beautiful "Down For Maintenance" page for your app in under 5 minutes.
Last updated 12 June 2020
The Wrenchmode add-on is currently in beta.
Table of Contents
WrenchMode is a fast and easy way to create a custom maintenance page for your web application. In less than 5 minutes you can have a great looking maintenance page for your application. Keep your users informed with real time updates, and when your maintenance is complete, all your waiting users are directed back to your application.
Provisioning the add-on
WrenchMode can be attached to a Heroku application via the CLI:
$ heroku addons:create wrenchmode
Using with Ruby
For your Ruby/Rack project you will start by including the
# In your Gemfile gem 'wrenchmode-rack'
Finally, make sure to include the middleware layer in your application.
# For Ruby on Rails, add this to /config/environments/production.rb config.middleware.insert_before 0, Wrenchmode::Rack # For a Rack application, add this to your-rack-app.rb require 'rubygems' require 'bundler/setup' Bundler.require(:default) use Wrenchmode::Rack
Once everything is installed, you can go to your Heroku Dashboard and click on the WrenchMode link to log into your Wrenchmode dashboard. From there you can turn Wrenchmode on and off for your project.
Using with NodeJS/Express
$ npm install wrenchmode-express
Finally, add WrenchMode to your app.js file.
// In your app.js var express = require('express'); var app = express(); var wrenchmodeExpress = require('wrenchmode-express'); app.use(wrenchmodeExpress());
You can change these settings if necessary, but it’s not recommended
When instantiating the middleware, you can set the following options:
|Force Open||Set to true to force the middleware layer to allow all requests through, regardless of project status on Wrenchmode.com. Effectively disables the middleware.||false|
|Ignore Test Mode||(Coming soon…) Set to false to if you want the middleware to respond to a project that is in Test mode on Wrenchmode.com This can be useful if you want to test Wrenchmode in a development or staging environment prior to deploying to production.||true|
|Disable Local Wrench||(Coming soon…) Set to true if you want to disable LocalWrench mode, where the Wrenchmode page is served on your domain. Disabling it will instead force a redirect to the Wrenchmode.com domain. Note: Unless you explicitly want this behavior, it’s best to leave this at the default.||true|
|Check Delay (Seconds)||Change this to modify the rate at which the middleware polls Wrenchmode for updates. Unlikely that this needs anything faster than the default.||5|
use Wrenchmode::Rack, jwt: "your-really-long-jwt", force_open: false, ignore_test_mode: true, disable_local_wrench: false, check_delay_secs: 5
The WrenchMode dashboard allows you to:
- Turn WrenchMode ON/ OFF
- Push live updates to users when WrenchMode is on
- Check your app connection and WM status
- Style your maintenance page
The dashboard can be accessed via the CLI:
$ heroku addons:open wrenchmode
or by visiting the Heroku Dashboard and selecting Wrenchmode from the list.
Removing the add-on
WrenchMode can be removed via the CLI.
This will destroy all associated data and cannot be undone!
$ heroku addons:destroy wrenchmmode