Create "config/settings/identity.yml"
This commit is contained in:
parent
249f9e2050
commit
921e1659b2
|
@ -3,5 +3,5 @@
|
|||
class ApplicationMailer < ActionMailer::Base
|
||||
layout 'mailer'
|
||||
|
||||
default from: Rails.application.config.noreply_email_contact
|
||||
default from: Rails.application.settings(:identity)[:noreply_email_contact]
|
||||
end
|
||||
|
|
|
@ -38,19 +38,11 @@ module Partynest
|
|||
# Initialize configuration defaults for originally generated Rails version.
|
||||
config.load_defaults 5.2
|
||||
|
||||
# Fully qualified domain name.
|
||||
config.site_domain = 'libertarian-party.com'
|
||||
|
||||
# Custom directories with classes and modules you want to be autoloadable.
|
||||
config.autoload_paths += [
|
||||
config.root.join('app', 'validators'),
|
||||
]
|
||||
|
||||
# Email which all mail is set from.
|
||||
config.noreply_email_address = "no-reply@#{config.site_domain}"
|
||||
config.noreply_email_contact =
|
||||
"Libertarian party of Russia <#{config.noreply_email_address}>"
|
||||
|
||||
# Use Sidekiq as ActiveJob adapter.
|
||||
config.active_job.queue_adapter = :sidekiq
|
||||
|
||||
|
|
|
@ -40,6 +40,7 @@ Rails.application.configure do
|
|||
config.action_mailer.perform_deliveries = true
|
||||
config.action_mailer.raise_delivery_errors = true
|
||||
config.action_mailer.perform_caching = false
|
||||
|
||||
config.action_mailer.default_url_options = {
|
||||
host: 'localhost',
|
||||
port: 3000,
|
||||
|
|
|
@ -83,7 +83,10 @@ Rails.application.configure do
|
|||
config.action_mailer.perform_deliveries = true
|
||||
config.action_mailer.raise_delivery_errors = true
|
||||
config.action_mailer.perform_caching = false
|
||||
config.action_mailer.default_url_options = { host: config.site_domain }
|
||||
|
||||
config.action_mailer.default_url_options = {
|
||||
host: Rails.application.settings(:identity)[:site_domain],
|
||||
}
|
||||
|
||||
# Enable locale fallbacks for I18n (makes lookups for any locale fall back to
|
||||
# the I18n.default_locale when a translation cannot be found).
|
||||
|
|
|
@ -41,6 +41,7 @@ Rails.application.configure do
|
|||
config.action_mailer.perform_deliveries = true
|
||||
config.action_mailer.raise_delivery_errors = true
|
||||
config.action_mailer.perform_caching = false
|
||||
|
||||
config.action_mailer.default_url_options = {
|
||||
host: 'localhost',
|
||||
port: 3000,
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
default: &default
|
||||
# Fully qualified domain name.
|
||||
site_domain: 'libertarian-party.com'
|
||||
|
||||
# Email which all mail is sent from.
|
||||
noreply_email_address: 'no-reply@libertarian-party.com'
|
||||
noreply_email_contact: >-
|
||||
Libertarian party of Russia <no-reply@libertarian-party.com>
|
||||
|
||||
development:
|
||||
<<: *default
|
||||
|
||||
test:
|
||||
<<: *default
|
||||
|
||||
production:
|
||||
<<: *default
|
Reference in New Issue