generated from dxw/rails-template
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Show environment for the newly added dev domain
All non-production environments show a banner in the top left corner of the page, and a prefix in emails sent from the application, to indicate what environment they are coming from. This is in order to avoid user confusion about what site they are on, and reassure them that they are not accidentally modifying production data without intending to. We cannot use Rails.env, because the Rails env is production for all - in that they are live sites, not local dev or testing. We have to use the hostname from the `DOMAIN` environment variable. When we originally added the banner, there was no dev environment, and the script defaults to not showing a banner for any unrecognised hosts, to avoid showing a banner unintentionally.
- Loading branch information
1 parent
4d892ba
commit 3e3a6dd
Showing
3 changed files
with
19 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters