* make the nobody@jamkazam.com configurable so that we can override it in chef to provide context clues
This commit is contained in:
parent
39f45f20ba
commit
091f2be556
|
|
@ -43,4 +43,6 @@ JamAdmin::Application.configure do
|
||||||
|
|
||||||
# Show the logging configuration on STDOUT
|
# Show the logging configuration on STDOUT
|
||||||
config.show_log_configuration = true
|
config.show_log_configuration = true
|
||||||
|
|
||||||
|
config.email_generic_from = 'nobody-dev@jamkazam.com'
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,8 @@ module JamRuby
|
||||||
sendgrid_unique_args :env => Environment.mode
|
sendgrid_unique_args :env => Environment.mode
|
||||||
|
|
||||||
def alerts(options)
|
def alerts(options)
|
||||||
mail(to: APP_CONFIG.email_alerts_alias,
|
mail(to: APP_CONFIG.email_recurly_notice,
|
||||||
|
from: APP_CONFIG.email_generic_from,
|
||||||
body: options[:body],
|
body: options[:body],
|
||||||
content_type: "text/plain",
|
content_type: "text/plain",
|
||||||
subject: options[:subject])
|
subject: options[:subject])
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,10 @@ def app_config
|
||||||
'alerts@jamkazam.com'
|
'alerts@jamkazam.com'
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def email_recurly_notice
|
||||||
|
'recurly-alerts@jamkazam.com'
|
||||||
|
end
|
||||||
|
|
||||||
def email_generic_from
|
def email_generic_from
|
||||||
'nobody@jamkazam.com'
|
'nobody@jamkazam.com'
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -222,6 +222,7 @@ if defined?(Bundler)
|
||||||
|
|
||||||
config.email_alerts_alias = 'alerts@jamkazam.com' # should be used for 'oh no' server down/service down sorts of emails
|
config.email_alerts_alias = 'alerts@jamkazam.com' # should be used for 'oh no' server down/service down sorts of emails
|
||||||
config.email_generic_from = 'nobody@jamkazam.com'
|
config.email_generic_from = 'nobody@jamkazam.com'
|
||||||
|
config.email_recurly_notice = 'recurly-alerts@jamkazam.com'
|
||||||
config.email_smtp_address = 'smtp.sendgrid.net'
|
config.email_smtp_address = 'smtp.sendgrid.net'
|
||||||
config.email_smtp_port = 587
|
config.email_smtp_port = 587
|
||||||
config.email_smtp_domain = 'www.jamkazam.com'
|
config.email_smtp_domain = 'www.jamkazam.com'
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,14 @@
|
||||||
def web_config
|
def web_config
|
||||||
klass = Class.new do
|
klass = Class.new do
|
||||||
|
|
||||||
|
def email_recurly_notice
|
||||||
|
'recurly-alerts@jamkazam.com'
|
||||||
|
end
|
||||||
|
|
||||||
|
def email_generic_from
|
||||||
|
'nobody@jamkazam.com'
|
||||||
|
end
|
||||||
|
|
||||||
def external_hostname
|
def external_hostname
|
||||||
Capybara.current_session.server.host
|
Capybara.current_session.server.host
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue