From efb461583b60f1e86f56ae660c775b7a821ed731 Mon Sep 17 00:00:00 2001 From: Michael Date: Wed, 16 Sep 2020 06:08:30 +0000 Subject: [PATCH] Move default setting to the configuration file --- src/Module/Admin/Site.php | 2 +- static/settings.config.php | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/Module/Admin/Site.php b/src/Module/Admin/Site.php index ee7840565..208748676 100644 --- a/src/Module/Admin/Site.php +++ b/src/Module/Admin/Site.php @@ -698,7 +698,7 @@ class Site extends BaseAdmin '$worker_frontend' => ['worker_frontend', DI::l10n()->t('Enable frontend worker'), DI::config()->get('system', 'frontend_worker'), DI::l10n()->t('When enabled the Worker process is triggered when backend access is performed (e.g. messages being delivered). On smaller sites you might want to call %s/worker on a regular basis via an external cron job. You should only enable this option if you cannot utilize cron/scheduled jobs on your server.', DI::baseUrl()->get())], '$relay_subscribe' => ['relay_subscribe', DI::l10n()->t('Subscribe to relay'), DI::config()->get('system', 'relay_subscribe'), DI::l10n()->t('Enables the receiving of public posts from the relay. They will be included in the search, subscribed tags and on the global community page.')], - '$relay_server' => ['relay_server', DI::l10n()->t('Relay server'), DI::config()->get('system', 'relay_server', 'https://social-relay.isurf.ca'), DI::l10n()->t('Address of the relay server where public posts should be send to. For example %s', 'https://social-relay.isurf.ca')], + '$relay_server' => ['relay_server', DI::l10n()->t('Relay server'), DI::config()->get('system', 'relay_server'), DI::l10n()->t('Address of the relay server where public posts should be send to. For example %s', 'https://social-relay.isurf.ca')], '$relay_directly' => ['relay_directly', DI::l10n()->t('Direct relay transfer'), DI::config()->get('system', 'relay_directly'), DI::l10n()->t('Enables the direct transfer to other servers without using the relay servers')], '$relay_scope' => ['relay_scope', DI::l10n()->t('Relay scope'), DI::config()->get('system', 'relay_scope'), DI::l10n()->t('Can be "all" or "tags". "all" means that every public post should be received. "tags" means that only posts with selected tags should be received.'), ['' => DI::l10n()->t('Disabled'), 'all' => DI::l10n()->t('all'), 'tags' => DI::l10n()->t('tags')]], '$relay_server_tags' => ['relay_server_tags', DI::l10n()->t('Server tags'), DI::config()->get('system', 'relay_server_tags'), DI::l10n()->t('Comma separated list of tags for the "tags" subscription.')], diff --git a/static/settings.config.php b/static/settings.config.php index 9dfd963b0..29f57f4af 100644 --- a/static/settings.config.php +++ b/static/settings.config.php @@ -122,6 +122,10 @@ return [ // Maximum system load before delivery and poll processes are deferred. 'maxloadavg' => 20, + // relay_server (String) + // Address of the relay server where public posts should be send to. + 'relay_server' => 'https://social-relay.isurf.ca', + // rino_encrypt (Integer) // Server-to-server private message encryption (RINO). // Encryption will only be provided if this setting is set to a non zero value on both servers.