Skip to content

Open source, privacy-first web analytics. Lightweight, cookie-free Google Analytics alternative. Self-hosted or cloud.

default to invite_only in ce (#4616)

ruslandogac8291639e511
diff --git a/config/runtime.exs b/config/runtime.exs
index 22fdeb37e4..aa1906df0d 100644
--- a/config/runtime.exs
+++ b/config/runtime.exs
@@ -255,8 +255,13 @@ is_selfhost =
|> get_var_from_path_or_env("SELFHOST", "true")
|> String.to_existing_atom()
-# by default, registration is disabled in self-hosted setups
-disable_registration_default = to_string(is_selfhost)
+# by default, only registration from invites is enabled in CE
+disable_registration_default =
+ if config_env() == :ce do
+ "invite_only"
+ else
+ "false"
+ end
disable_registration =
config_dir