diff options
Diffstat (limited to 'config')
-rw-r--r-- | config/config.exs | 7 | ||||
-rw-r--r-- | config/config.md | 14 | ||||
-rw-r--r-- | config/test.exs | 6 |
3 files changed, 26 insertions, 1 deletions
diff --git a/config/config.exs b/config/config.exs index df6ea09ae..036f1ac0b 100644 --- a/config/config.exs +++ b/config/config.exs @@ -10,6 +10,13 @@ config :pleroma, ecto_repos: [Pleroma.Repo] config :pleroma, Pleroma.Repo, types: Pleroma.PostgresTypes +config :pleroma, Pleroma.Captcha, + enabled: false, + seconds_retained: 180, + method: Pleroma.Captcha.Kocaptcha + +config :pleroma, Pleroma.Captcha.Kocaptcha, endpoint: "https://captcha.kotobank.ch" + # Upload configuration config :pleroma, Pleroma.Upload, uploader: Pleroma.Uploaders.Local, diff --git a/config/config.md b/config/config.md index 8282eab14..edabd6e0f 100644 --- a/config/config.md +++ b/config/config.md @@ -7,7 +7,7 @@ If you run Pleroma with ``MIX_ENV=prod`` the file is ``prod.secret.exs``, otherw * `uploader`: Select which `Pleroma.Uploaders` to use * `filters`: List of `Pleroma.Upload.Filter` to use. * `base_url`: The base URL to access a user-uploaded file. Useful when you want to proxy the media files via another host. -* `proxy_remote`: If you're using a remote uploader, Pleroma will proxy media requests instead of redirecting to it. +* `proxy_remote`: If you\'re using a remote uploader, Pleroma will proxy media requests instead of redirecting to it. * `proxy_opts`: Proxy options, see `Pleroma.ReverseProxy` documentation. Note: `strip_exif` has been replaced by `Pleroma.Upload.Filter.Mogrify`. @@ -163,3 +163,15 @@ Web Push Notifications configuration. You can use the mix task `mix web_push.gen * ``subject``: a mailto link for the administrative contact. It’s best if this email is not a personal email address, but rather a group email so that if a person leaves an organization, is unavailable for an extended period, or otherwise can’t respond, someone else on the list can. * ``public_key``: VAPID public key * ``private_key``: VAPID private key + +## Pleroma.Captcha +* `enabled`: Whether the captcha should be shown on registration +* `method`: The method/service to use for captcha +* `seconds_retained`: The time in seconds for which the captcha is valid (stored in the cache) + +### Pleroma.Captcha.Kocaptcha +Kocaptcha is a very simple captcha service with a single API endpoint, +the source code is here: https://github.com/koto-bank/kocaptcha. The default endpoint +`https://captcha.kotobank.ch` is hosted by the developer. + +* `endpoint`: the kocaptcha endpoint to use
\ No newline at end of file diff --git a/config/test.exs b/config/test.exs index 8f4a2dc17..51aace407 100644 --- a/config/test.exs +++ b/config/test.exs @@ -7,6 +7,12 @@ config :pleroma, Pleroma.Web.Endpoint, url: [port: 4001], server: true +# Disable captha for tests +config :pleroma, Pleroma.Captcha, + enabled: true, + # A fake captcha service for tests + method: Pleroma.Captcha.Mock + # Print only warnings and errors during test config :logger, level: :warn |