Refactor settings model
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
Move the various sections to their own concerns, so they're easier to find and maintain
This commit is contained in:
parent
45137e0cfe
commit
4ae10c9b53
24
app/models/concerns/settings/btcpay_settings.rb
Normal file
24
app/models/concerns/settings/btcpay_settings.rb
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
module Settings
|
||||||
|
module BtcpaySettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :btcpay_api_url, type: :string,
|
||||||
|
default: ENV["BTCPAY_API_URL"].presence
|
||||||
|
|
||||||
|
field :btcpay_enabled, type: :boolean,
|
||||||
|
default: ENV["BTCPAY_API_URL"].present?
|
||||||
|
|
||||||
|
field :btcpay_public_url, type: :string,
|
||||||
|
default: ENV["BTCPAY_PUBLIC_URL"].presence
|
||||||
|
|
||||||
|
field :btcpay_store_id, type: :string,
|
||||||
|
default: ENV["BTCPAY_STORE_ID"].presence
|
||||||
|
|
||||||
|
field :btcpay_auth_token, type: :string,
|
||||||
|
default: ENV["BTCPAY_AUTH_TOKEN"].presence
|
||||||
|
|
||||||
|
field :btcpay_publish_wallet_balances, type: :boolean, default: true
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
16
app/models/concerns/settings/discourse_settings.rb
Normal file
16
app/models/concerns/settings/discourse_settings.rb
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
module Settings
|
||||||
|
module DiscourseSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :discourse_public_url, type: :string,
|
||||||
|
default: ENV["DISCOURSE_PUBLIC_URL"].presence
|
||||||
|
|
||||||
|
field :discourse_enabled, type: :boolean,
|
||||||
|
default: ENV["DISCOURSE_PUBLIC_URL"].present?
|
||||||
|
|
||||||
|
field :discourse_connect_secret, type: :string,
|
||||||
|
default: ENV["DISCOURSE_CONNECT_SECRET"].presence
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
13
app/models/concerns/settings/drone_ci_settings.rb
Normal file
13
app/models/concerns/settings/drone_ci_settings.rb
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
module Settings
|
||||||
|
module DroneCiSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :droneci_public_url, type: :string,
|
||||||
|
default: ENV["DRONECI_PUBLIC_URL"].presence
|
||||||
|
|
||||||
|
field :droneci_enabled, type: :boolean,
|
||||||
|
default: ENV["DRONECI_PUBLIC_URL"].present?
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
19
app/models/concerns/settings/ejabberd_settings.rb
Normal file
19
app/models/concerns/settings/ejabberd_settings.rb
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
module Settings
|
||||||
|
module EjabberdSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :ejabberd_enabled, type: :boolean,
|
||||||
|
default: ENV["EJABBERD_API_URL"].present?
|
||||||
|
|
||||||
|
field :ejabberd_api_url, type: :string,
|
||||||
|
default: ENV["EJABBERD_API_URL"].presence
|
||||||
|
|
||||||
|
field :ejabberd_admin_url, type: :string,
|
||||||
|
default: ENV["EJABBERD_ADMIN_URL"].presence
|
||||||
|
|
||||||
|
field :ejabberd_buddy_roster, type: :string,
|
||||||
|
default: "Buddies"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
28
app/models/concerns/settings/email_settings.rb
Normal file
28
app/models/concerns/settings/email_settings.rb
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
module Settings
|
||||||
|
module EmailSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :email_enabled, type: :boolean,
|
||||||
|
default: ENV["EMAIL_SMTP_HOST"].present?
|
||||||
|
|
||||||
|
# field :email_smtp_host, type: :string,
|
||||||
|
# default: ENV["EMAIL_SMTP_HOST"].presence
|
||||||
|
#
|
||||||
|
# field :email_smtp_port, type: :string,
|
||||||
|
# default: ENV["EMAIL_SMTP_PORT"].presence || 587
|
||||||
|
#
|
||||||
|
# field :email_smtp_enable_starttls, type: :string,
|
||||||
|
# default: ENV["EMAIL_SMTP_PORT"].presence || true
|
||||||
|
#
|
||||||
|
# field :email_auth_method, type: :string,
|
||||||
|
# default: ENV["EMAIL_AUTH_METHOD"].presence || "plain"
|
||||||
|
#
|
||||||
|
# field :email_imap_host, type: :string,
|
||||||
|
# default: ENV["EMAIL_IMAP_HOST"].presence
|
||||||
|
#
|
||||||
|
# field :email_imap_port, type: :string,
|
||||||
|
# default: ENV["EMAIL_IMAP_PORT"].presence || 993
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
34
app/models/concerns/settings/general_settings.rb
Normal file
34
app/models/concerns/settings/general_settings.rb
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
module Settings
|
||||||
|
module GeneralSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :primary_domain, type: :string,
|
||||||
|
default: ENV["PRIMARY_DOMAIN"].presence
|
||||||
|
|
||||||
|
field :accounts_domain, type: :string,
|
||||||
|
default: ENV["AKKOUNTS_DOMAIN"].presence
|
||||||
|
|
||||||
|
#
|
||||||
|
# Internal services
|
||||||
|
#
|
||||||
|
|
||||||
|
field :redis_url, type: :string,
|
||||||
|
default: ENV["REDIS_URL"] || "redis://localhost:6379/0"
|
||||||
|
|
||||||
|
field :s3_enabled, type: :boolean,
|
||||||
|
default: ENV["S3_ENABLED"] && ENV["S3_ENABLED"].to_s != "false"
|
||||||
|
|
||||||
|
field :sentry_enabled, type: :boolean, readonly: true,
|
||||||
|
default: ENV["SENTRY_DSN"].present?
|
||||||
|
|
||||||
|
#
|
||||||
|
# Registrations
|
||||||
|
#
|
||||||
|
|
||||||
|
field :reserved_usernames, type: :array, default: %w[
|
||||||
|
account accounts donations mail webmaster support
|
||||||
|
]
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
13
app/models/concerns/settings/gitea_settings.rb
Normal file
13
app/models/concerns/settings/gitea_settings.rb
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
module Settings
|
||||||
|
module GiteaSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :gitea_public_url, type: :string,
|
||||||
|
default: ENV["GITEA_PUBLIC_URL"].presence
|
||||||
|
|
||||||
|
field :gitea_enabled, type: :boolean,
|
||||||
|
default: ENV["GITEA_PUBLIC_URL"].present?
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
25
app/models/concerns/settings/lightning_network_settings.rb
Normal file
25
app/models/concerns/settings/lightning_network_settings.rb
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
module Settings
|
||||||
|
module LightningNetworkSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :lndhub_api_url, type: :string,
|
||||||
|
default: ENV["LNDHUB_API_URL"].presence
|
||||||
|
|
||||||
|
field :lndhub_enabled, type: :boolean,
|
||||||
|
default: ENV["LNDHUB_API_URL"].present?
|
||||||
|
|
||||||
|
field :lndhub_admin_token, type: :string,
|
||||||
|
default: ENV["LNDHUB_ADMIN_TOKEN"].presence
|
||||||
|
|
||||||
|
field :lndhub_admin_enabled, type: :boolean,
|
||||||
|
default: ENV["LNDHUB_ADMIN_UI"] || false
|
||||||
|
|
||||||
|
field :lndhub_public_key, type: :string,
|
||||||
|
default: (ENV["LNDHUB_PUBLIC_KEY"] || "")
|
||||||
|
|
||||||
|
field :lndhub_keysend_enabled, type: :boolean,
|
||||||
|
default: -> { self.lndhub_public_key.present? }
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
16
app/models/concerns/settings/mastodon_settings.rb
Normal file
16
app/models/concerns/settings/mastodon_settings.rb
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
module Settings
|
||||||
|
module MastodonSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :mastodon_public_url, type: :string,
|
||||||
|
default: ENV["MASTODON_PUBLIC_URL"].presence
|
||||||
|
|
||||||
|
field :mastodon_enabled, type: :boolean,
|
||||||
|
default: ENV["MASTODON_PUBLIC_URL"].present?
|
||||||
|
|
||||||
|
field :mastodon_address_domain, type: :string,
|
||||||
|
default: ENV["MASTODON_ADDRESS_DOMAIN"].presence || self.primary_domain
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
13
app/models/concerns/settings/media_wiki_settings.rb
Normal file
13
app/models/concerns/settings/media_wiki_settings.rb
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
module Settings
|
||||||
|
module MediaWikiSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :mediawiki_public_url, type: :string,
|
||||||
|
default: ENV["MEDIAWIKI_PUBLIC_URL"].presence
|
||||||
|
|
||||||
|
field :mediawiki_enabled, type: :boolean,
|
||||||
|
default: ENV["MEDIAWIKI_PUBLIC_URL"].present?
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
22
app/models/concerns/settings/nostr_settings.rb
Normal file
22
app/models/concerns/settings/nostr_settings.rb
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
module Settings
|
||||||
|
module NostrSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :nostr_enabled, type: :boolean,
|
||||||
|
default: ENV["NOSTR_PRIVATE_KEY"].present?
|
||||||
|
|
||||||
|
field :nostr_private_key, type: :string,
|
||||||
|
default: ENV["NOSTR_PRIVATE_KEY"].presence
|
||||||
|
|
||||||
|
field :nostr_public_key, type: :string,
|
||||||
|
default: ENV["NOSTR_PUBLIC_KEY"].presence
|
||||||
|
|
||||||
|
field :nostr_relay_url, type: :string,
|
||||||
|
default: ENV["NOSTR_RELAY_URL"].presence
|
||||||
|
|
||||||
|
field :nostr_zaps_relay_limit, type: :integer,
|
||||||
|
default: 12
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
9
app/models/concerns/settings/open_collective_settings.rb
Normal file
9
app/models/concerns/settings/open_collective_settings.rb
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
module Settings
|
||||||
|
module OpenCollectiveSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :opencollective_enabled, type: :boolean, default: true
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
16
app/models/concerns/settings/remote_storage_settings.rb
Normal file
16
app/models/concerns/settings/remote_storage_settings.rb
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
module Settings
|
||||||
|
module RemoteStorageSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :remotestorage_enabled, type: :boolean,
|
||||||
|
default: ENV["RS_STORAGE_URL"].present?
|
||||||
|
|
||||||
|
field :rs_storage_url, type: :string,
|
||||||
|
default: ENV["RS_STORAGE_URL"].presence
|
||||||
|
|
||||||
|
field :rs_redis_url, type: :string,
|
||||||
|
default: ENV["RS_REDIS_URL"] || "redis://localhost:6379/1"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
11
app/models/concerns/settings/xmpp_settings.rb
Normal file
11
app/models/concerns/settings/xmpp_settings.rb
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
module Settings
|
||||||
|
module XmppSettings
|
||||||
|
extend ActiveSupport::Concern
|
||||||
|
|
||||||
|
included do
|
||||||
|
field :xmpp_default_rooms, type: :array, default: []
|
||||||
|
field :xmpp_autojoin_default_rooms, type: :boolean, default: false
|
||||||
|
field :xmpp_notifications_from_address, type: :string, default: primary_domain
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
@ -2,223 +2,24 @@
|
|||||||
class Setting < RailsSettings::Base
|
class Setting < RailsSettings::Base
|
||||||
cache_prefix { "v1" }
|
cache_prefix { "v1" }
|
||||||
|
|
||||||
field :primary_domain, type: :string,
|
Dir[Rails.root.join('app', 'models', 'concerns', 'settings', '*.rb')].each do |file|
|
||||||
default: ENV["PRIMARY_DOMAIN"].presence
|
require file
|
||||||
|
end
|
||||||
|
|
||||||
field :accounts_domain, type: :string,
|
include Settings::GeneralSettings
|
||||||
default: ENV["AKKOUNTS_DOMAIN"].presence
|
include Settings::BtcpaySettings
|
||||||
|
include Settings::DiscourseSettings
|
||||||
#
|
include Settings::DroneCiSettings
|
||||||
# Internal services
|
include Settings::EjabberdSettings
|
||||||
#
|
include Settings::EmailSettings
|
||||||
|
include Settings::GiteaSettings
|
||||||
field :redis_url, type: :string,
|
include Settings::LightningNetworkSettings
|
||||||
default: ENV["REDIS_URL"] || "redis://localhost:6379/0"
|
include Settings::MastodonSettings
|
||||||
|
include Settings::MediaWikiSettings
|
||||||
field :s3_enabled, type: :boolean,
|
include Settings::NostrSettings
|
||||||
default: ENV["S3_ENABLED"] && ENV["S3_ENABLED"].to_s != "false"
|
include Settings::OpenCollectiveSettings
|
||||||
|
include Settings::RemoteStorageSettings
|
||||||
#
|
include Settings::XmppSettings
|
||||||
# Registrations
|
|
||||||
#
|
|
||||||
|
|
||||||
field :reserved_usernames, type: :array, default: %w[
|
|
||||||
account accounts donations mail webmaster support
|
|
||||||
]
|
|
||||||
|
|
||||||
#
|
|
||||||
# XMPP
|
|
||||||
#
|
|
||||||
|
|
||||||
field :xmpp_default_rooms, type: :array, default: []
|
|
||||||
field :xmpp_autojoin_default_rooms, type: :boolean, default: false
|
|
||||||
field :xmpp_notifications_from_address, type: :string, default: primary_domain
|
|
||||||
|
|
||||||
#
|
|
||||||
# Sentry
|
|
||||||
#
|
|
||||||
|
|
||||||
field :sentry_enabled, type: :boolean, readonly: true,
|
|
||||||
default: ENV["SENTRY_DSN"].present?
|
|
||||||
|
|
||||||
#
|
|
||||||
# BTCPay Server
|
|
||||||
#
|
|
||||||
|
|
||||||
field :btcpay_api_url, type: :string,
|
|
||||||
default: ENV["BTCPAY_API_URL"].presence
|
|
||||||
|
|
||||||
field :btcpay_enabled, type: :boolean,
|
|
||||||
default: ENV["BTCPAY_API_URL"].present?
|
|
||||||
|
|
||||||
field :btcpay_public_url, type: :string,
|
|
||||||
default: ENV["BTCPAY_PUBLIC_URL"].presence
|
|
||||||
|
|
||||||
field :btcpay_store_id, type: :string,
|
|
||||||
default: ENV["BTCPAY_STORE_ID"].presence
|
|
||||||
|
|
||||||
field :btcpay_auth_token, type: :string,
|
|
||||||
default: ENV["BTCPAY_AUTH_TOKEN"].presence
|
|
||||||
|
|
||||||
field :btcpay_publish_wallet_balances, type: :boolean, default: true
|
|
||||||
|
|
||||||
#
|
|
||||||
# Discourse
|
|
||||||
#
|
|
||||||
|
|
||||||
field :discourse_public_url, type: :string,
|
|
||||||
default: ENV["DISCOURSE_PUBLIC_URL"].presence
|
|
||||||
|
|
||||||
field :discourse_enabled, type: :boolean,
|
|
||||||
default: ENV["DISCOURSE_PUBLIC_URL"].present?
|
|
||||||
|
|
||||||
field :discourse_connect_secret, type: :string,
|
|
||||||
default: ENV["DISCOURSE_CONNECT_SECRET"].presence
|
|
||||||
|
|
||||||
#
|
|
||||||
# Drone CI
|
|
||||||
#
|
|
||||||
|
|
||||||
field :droneci_public_url, type: :string,
|
|
||||||
default: ENV["DRONECI_PUBLIC_URL"].presence
|
|
||||||
|
|
||||||
field :droneci_enabled, type: :boolean,
|
|
||||||
default: ENV["DRONECI_PUBLIC_URL"].present?
|
|
||||||
|
|
||||||
#
|
|
||||||
# ejabberd
|
|
||||||
#
|
|
||||||
|
|
||||||
field :ejabberd_enabled, type: :boolean,
|
|
||||||
default: ENV["EJABBERD_API_URL"].present?
|
|
||||||
|
|
||||||
field :ejabberd_api_url, type: :string,
|
|
||||||
default: ENV["EJABBERD_API_URL"].presence
|
|
||||||
|
|
||||||
field :ejabberd_admin_url, type: :string,
|
|
||||||
default: ENV["EJABBERD_ADMIN_URL"].presence
|
|
||||||
|
|
||||||
field :ejabberd_buddy_roster, type: :string,
|
|
||||||
default: "Buddies"
|
|
||||||
|
|
||||||
#
|
|
||||||
# Gitea
|
|
||||||
#
|
|
||||||
|
|
||||||
field :gitea_public_url, type: :string,
|
|
||||||
default: ENV["GITEA_PUBLIC_URL"].presence
|
|
||||||
|
|
||||||
field :gitea_enabled, type: :boolean,
|
|
||||||
default: ENV["GITEA_PUBLIC_URL"].present?
|
|
||||||
|
|
||||||
#
|
|
||||||
# Lightning Network
|
|
||||||
#
|
|
||||||
|
|
||||||
field :lndhub_api_url, type: :string,
|
|
||||||
default: ENV["LNDHUB_API_URL"].presence
|
|
||||||
|
|
||||||
field :lndhub_enabled, type: :boolean,
|
|
||||||
default: ENV["LNDHUB_API_URL"].present?
|
|
||||||
|
|
||||||
field :lndhub_admin_token, type: :string,
|
|
||||||
default: ENV["LNDHUB_ADMIN_TOKEN"].presence
|
|
||||||
|
|
||||||
field :lndhub_admin_enabled, type: :boolean,
|
|
||||||
default: ENV["LNDHUB_ADMIN_UI"] || false
|
|
||||||
|
|
||||||
field :lndhub_public_key, type: :string,
|
|
||||||
default: (ENV["LNDHUB_PUBLIC_KEY"] || "")
|
|
||||||
|
|
||||||
field :lndhub_keysend_enabled, type: :boolean,
|
|
||||||
default: -> { self.lndhub_public_key.present? }
|
|
||||||
|
|
||||||
#
|
|
||||||
# Mastodon
|
|
||||||
#
|
|
||||||
|
|
||||||
field :mastodon_public_url, type: :string,
|
|
||||||
default: ENV["MASTODON_PUBLIC_URL"].presence
|
|
||||||
|
|
||||||
field :mastodon_enabled, type: :boolean,
|
|
||||||
default: ENV["MASTODON_PUBLIC_URL"].present?
|
|
||||||
|
|
||||||
field :mastodon_address_domain, type: :string,
|
|
||||||
default: ENV["MASTODON_ADDRESS_DOMAIN"].presence || self.primary_domain
|
|
||||||
|
|
||||||
#
|
|
||||||
# MediaWiki
|
|
||||||
#
|
|
||||||
|
|
||||||
field :mediawiki_public_url, type: :string,
|
|
||||||
default: ENV["MEDIAWIKI_PUBLIC_URL"].presence
|
|
||||||
|
|
||||||
field :mediawiki_enabled, type: :boolean,
|
|
||||||
default: ENV["MEDIAWIKI_PUBLIC_URL"].present?
|
|
||||||
|
|
||||||
#
|
|
||||||
# Nostr
|
|
||||||
#
|
|
||||||
|
|
||||||
field :nostr_enabled, type: :boolean,
|
|
||||||
default: ENV["NOSTR_PRIVATE_KEY"].present?
|
|
||||||
|
|
||||||
field :nostr_private_key, type: :string,
|
|
||||||
default: ENV["NOSTR_PRIVATE_KEY"].presence
|
|
||||||
|
|
||||||
field :nostr_public_key, type: :string,
|
|
||||||
default: ENV["NOSTR_PUBLIC_KEY"].presence
|
|
||||||
|
|
||||||
field :nostr_relay_url, type: :string,
|
|
||||||
default: ENV["NOSTR_RELAY_URL"].presence
|
|
||||||
|
|
||||||
field :nostr_zaps_relay_limit, type: :integer,
|
|
||||||
default: 12
|
|
||||||
|
|
||||||
#
|
|
||||||
# OpenCollective
|
|
||||||
#
|
|
||||||
|
|
||||||
field :opencollective_enabled, type: :boolean, default: true
|
|
||||||
|
|
||||||
#
|
|
||||||
# RemoteStorage
|
|
||||||
#
|
|
||||||
|
|
||||||
field :remotestorage_enabled, type: :boolean,
|
|
||||||
default: ENV["RS_STORAGE_URL"].present?
|
|
||||||
|
|
||||||
field :rs_storage_url, type: :string,
|
|
||||||
default: ENV["RS_STORAGE_URL"].presence
|
|
||||||
|
|
||||||
field :rs_redis_url, type: :string,
|
|
||||||
default: ENV["RS_REDIS_URL"] || "redis://localhost:6379/1"
|
|
||||||
|
|
||||||
|
|
||||||
#
|
|
||||||
# E-Mail Service
|
|
||||||
#
|
|
||||||
|
|
||||||
field :email_enabled, type: :boolean,
|
|
||||||
default: ENV["EMAIL_SMTP_HOST"].present?
|
|
||||||
|
|
||||||
# field :email_smtp_host, type: :string,
|
|
||||||
# default: ENV["EMAIL_SMTP_HOST"].presence
|
|
||||||
#
|
|
||||||
# field :email_smtp_port, type: :string,
|
|
||||||
# default: ENV["EMAIL_SMTP_PORT"].presence || 587
|
|
||||||
#
|
|
||||||
# field :email_smtp_enable_starttls, type: :string,
|
|
||||||
# default: ENV["EMAIL_SMTP_PORT"].presence || true
|
|
||||||
#
|
|
||||||
# field :email_auth_method, type: :string,
|
|
||||||
# default: ENV["EMAIL_AUTH_METHOD"].presence || "plain"
|
|
||||||
#
|
|
||||||
# field :email_imap_host, type: :string,
|
|
||||||
# default: ENV["EMAIL_IMAP_HOST"].presence
|
|
||||||
#
|
|
||||||
# field :email_imap_port, type: :string,
|
|
||||||
# default: ENV["EMAIL_IMAP_PORT"].presence || 993
|
|
||||||
|
|
||||||
def self.default_services
|
def self.default_services
|
||||||
# TODO Make configurable from respective service settings page
|
# TODO Make configurable from respective service settings page
|
||||||
|
Loading…
x
Reference in New Issue
Block a user