added CONFIGURATION.md containing some details about configuring mrf
This commit is contained in:
parent
07f0cfa53f
commit
837792b015
1 changed files with 60 additions and 0 deletions
60
CONFIGURATION.md
Normal file
60
CONFIGURATION.md
Normal file
|
@ -0,0 +1,60 @@
|
||||||
|
# Configuring Pleroma
|
||||||
|
|
||||||
|
In the `config/` directory, you will find the following relevant files:
|
||||||
|
* `config.exs`: default base configuration
|
||||||
|
* `dev.exs`: default additional configuration for `MIX_ENV=dev`
|
||||||
|
* `prod.exs`: default additional configuration for `MIX_ENV=prod`
|
||||||
|
|
||||||
|
Additionally, you can overload options in the following files:
|
||||||
|
* `dev.secret.exs`: additional custom configuration for `MIX_ENV=dev`
|
||||||
|
* `prod.secret.exs`: additional custom configuration for `MIX_ENV=prod`
|
||||||
|
|
||||||
|
## Message Rewrite Filters (MRFs)
|
||||||
|
|
||||||
|
Modify incoming and outgoing posts.
|
||||||
|
|
||||||
|
config :pleroma, :instance,
|
||||||
|
rewrite_policy: Pleroma.Web.ActivityPub.MRF.NoOpPolicy
|
||||||
|
|
||||||
|
`rewrite_policy` specifies which MRF policies to apply. It can either be a single policy or a list of policies.
|
||||||
|
Currently, MRFs availible by default are:
|
||||||
|
* `Pleroma.Web.ActivityPub.MRF.NoOpPolicy`
|
||||||
|
* `Pleroma.Web.ActivityPub.MRF.DropPolicy`
|
||||||
|
* `Pleroma.Web.ActivityPub.MRF.SimplePolicy`
|
||||||
|
* `Pleroma.Web.ActivityPub.MRF.RejectNonPublic`
|
||||||
|
|
||||||
|
Some policies, such as SimplePolicy and RejectNonPublic, can be additionally configured in their respective sections.
|
||||||
|
|
||||||
|
### NoOpPolicy
|
||||||
|
|
||||||
|
Does not modify posts (this is the default `rewrite_policy`)
|
||||||
|
|
||||||
|
### DropPolicy
|
||||||
|
|
||||||
|
Drops all posts. It generally does not make sense to use this in production.
|
||||||
|
|
||||||
|
### SimplePolicy
|
||||||
|
|
||||||
|
Versatile policy for applying effects to posts from certain instances.
|
||||||
|
|
||||||
|
config :pleroma, :mrf_simple,
|
||||||
|
media_removal: [],
|
||||||
|
media_nsfw: [],
|
||||||
|
federated_timeline_removal: [],
|
||||||
|
reject: []
|
||||||
|
|
||||||
|
* `media_removal`: posts from these instances will have attachments removed
|
||||||
|
* `media_nsfw`: posts from these instances will have attachments marked as nsfw
|
||||||
|
* `federated_timeline_removal`: posts from these instances will be marked as unlisted
|
||||||
|
* `reject`: posts from these instances will be dropped
|
||||||
|
|
||||||
|
### RejectNonPublic
|
||||||
|
|
||||||
|
Drops posts with non-public visibility settings.
|
||||||
|
|
||||||
|
config :pleroma :mrf_rejectnonpublic
|
||||||
|
allow_followersonly: false,
|
||||||
|
allow_direct: false,
|
||||||
|
|
||||||
|
* `allow_followersonly`: whether to allow follower-only posts through the filter
|
||||||
|
* `allow_direct`: whether to allow direct messages through the filter
|
Loading…
Reference in a new issue