X-Git-Url: http://git.squeep.com/?a=blobdiff_plain;f=config%2Fdescription.exs;h=f54ac2a2a94d4e4b3350a7866b9708dc275ef268;hb=0883a706dc376fdfb7de9df1366803e87c8e7c98;hp=504161a9f4e8d430f277806d39ea3990ba5f9367;hpb=942093683a1e6b3f3d3692268b2af8390da6d325;p=akkoma diff --git a/config/description.exs b/config/description.exs index 504161a9f..f54ac2a2a 100644 --- a/config/description.exs +++ b/config/description.exs @@ -28,7 +28,8 @@ config :pleroma, :config_description, [ %{ key: :filters, type: {:list, :module}, - description: "List of filter modules for uploads", + description: + "List of filter modules for uploads. Module names are shortened (removed leading `Pleroma.Upload.Filter.` part), but on adding custom module you need to use full name.", suggestions: Generator.list_modules_in_dir( "lib/pleroma/upload/filter", @@ -118,6 +119,11 @@ config :pleroma, :config_description, [ ] } ] + }, + %{ + key: :filename_display_max_length, + type: :integer, + description: "Set max length of a filename to display. 0 = no limit. Default: 30" } ] }, @@ -678,29 +684,11 @@ config :pleroma, :config_description, [ 7 ] }, - %{ - key: :federation_publisher_modules, - type: {:list, :module}, - description: "List of modules for federation publishing", - suggestions: [ - Pleroma.Web.ActivityPub.Publisher - ] - }, %{ key: :allow_relay, type: :boolean, description: "Enable Pleroma's Relay, which makes it possible to follow a whole instance" }, - %{ - key: :rewrite_policy, - type: [:module, {:list, :module}], - description: "A list of MRF policies enabled", - suggestions: - Generator.list_modules_in_dir( - "lib/pleroma/web/activity_pub/mrf", - "Elixir.Pleroma.Web.ActivityPub.MRF." - ) - }, %{ key: :public, type: :boolean, @@ -743,23 +731,6 @@ config :pleroma, :config_description, [ "text/bbcode" ] }, - %{ - key: :mrf_transparency, - label: "MRF transparency", - type: :boolean, - description: - "Make the content of your Message Rewrite Facility settings public (via nodeinfo)" - }, - %{ - key: :mrf_transparency_exclusions, - label: "MRF transparency exclusions", - type: {:list, :string}, - description: - "Exclude specific instance names from MRF transparency. The use of the exclusions feature will be disclosed in nodeinfo as a boolean value.", - suggestions: [ - "exclusion.com" - ] - }, %{ key: :extended_nickname_format, type: :boolean, @@ -975,6 +946,13 @@ config :pleroma, :config_description, [ ] } ] + }, + %{ + key: :instance_thumbnail, + type: :string, + description: + "The instance thumbnail can be any image that represents your instance and is used by some apps or services when they display information about your instance.", + suggestions: ["/instance/thumbnail.jpeg"] } ] }, @@ -1102,38 +1080,41 @@ config :pleroma, :config_description, [ description: "Settings for Pleroma FE", suggestions: [ %{ - theme: "pleroma-dark", - logo: "/static/logo.png", - background: "/images/city.jpg", - redirectRootNoLogin: "/main/all", - redirectRootLogin: "/main/friends", - showInstanceSpecificPanel: true, - scopeOptionsEnabled: false, - formattingOptionsEnabled: false, + alwaysShowSubjectInput: true, + background: "/static/aurora_borealis.jpg", collapseMessageWithSubject: false, + disableChat: false, + greentext: false, + hideFilteredStatuses: false, + hideMutedPosts: false, hidePostStats: false, + hideSitename: false, hideUserStats: false, + loginMethod: "password", + logo: "/static/logo.png", + logoMargin: ".1em", + logoMask: true, + minimalScopesMode: false, + noAttachmentLinks: false, + nsfwCensorImage: "/static/img/nsfw.74818f9.png", + postContentType: "text/plain", + redirectRootLogin: "/main/friends", + redirectRootNoLogin: "/main/all", scopeCopy: true, + sidebarRight: false, + showFeaturesPanel: true, + showInstanceSpecificPanel: false, subjectLineBehavior: "email", - alwaysShowSubjectInput: true, - logoMask: false, - logoMargin: ".1em", - stickers: false, - enableEmojiPicker: false + theme: "pleroma-dark", + webPushNotifications: false } ], children: [ %{ - key: :theme, - type: :string, - description: "Which theme to use, they are defined in styles.json", - suggestions: ["pleroma-dark"] - }, - %{ - key: :logo, - type: :string, - description: "URL of the logo, defaults to Pleroma's logo", - suggestions: ["/static/logo.png"] + key: :alwaysShowSubjectInput, + label: "Always show subject input", + type: :boolean, + description: "When disabled, auto-hide the subject field if it's empty" }, %{ key: :background, @@ -1143,46 +1124,35 @@ config :pleroma, :config_description, [ suggestions: ["/images/city.jpg"] }, %{ - key: :redirectRootNoLogin, - label: "Redirect root no login", - type: :string, - description: - "Relative URL which indicates where to redirect when a user isn't logged in", - suggestions: ["/main/all"] - }, - %{ - key: :redirectRootLogin, - label: "Redirect root login", - type: :string, + key: :collapseMessageWithSubject, + label: "Collapse message with subject", + type: :boolean, description: - "Relative URL which indicates where to redirect when a user is logged in", - suggestions: ["/main/friends"] + "When a message has a subject (aka Content Warning), collapse it by default" }, %{ - key: :showInstanceSpecificPanel, - label: "Show instance specific panel", + key: :disableChat, + label: "PleromaFE Chat", type: :boolean, - description: "Whenether to show the instance's specific panel" + description: "Disables PleromaFE Chat component" }, %{ - key: :scopeOptionsEnabled, - label: "Scope options enabled", + key: :greentext, + label: "Greentext", type: :boolean, - description: "Enable setting a notice visibility and subject/CW when posting" + description: "Enables green text on lines prefixed with the > character." }, %{ - key: :formattingOptionsEnabled, - label: "Formatting options enabled", + key: :hideFilteredStatuses, + label: "Hide Filtered Statuses", type: :boolean, - description: - "Enable setting a formatting different than plain-text (ie. HTML, Markdown) when posting, relates to `:instance`, `allowed_post_formats`" + description: "Hides filtered statuses from timelines." }, %{ - key: :collapseMessageWithSubject, - label: "Collapse message with subject", + key: :hideMutedPosts, + label: "Hide Muted Posts", type: :boolean, - description: - "When a message has a subject (aka Content Warning), collapse it by default" + description: "Hides muted statuses from timelines." }, %{ key: :hidePostStats, @@ -1190,6 +1160,12 @@ config :pleroma, :config_description, [ type: :boolean, description: "Hide notices statistics (repeats, favorites, ...)" }, + %{ + key: :hideSitename, + label: "Hide Sitename", + type: :boolean, + description: "Hides instance name from PleromaFE banner." + }, %{ key: :hideUserStats, label: "Hide user stats", @@ -1198,26 +1174,19 @@ config :pleroma, :config_description, [ "Hide profile statistics (posts, posts per day, followers, followings, ...)" }, %{ - key: :scopeCopy, - label: "Scope copy", - type: :boolean, - description: "Copy the scope (private/unlisted/public) in replies to posts by default" - }, - %{ - key: :subjectLineBehavior, - label: "Subject line behavior", + key: :logo, type: :string, - description: "Allows changing the default behaviour of subject lines in replies. - `email`: copy and preprend re:, as in email, - `masto`: copy verbatim, as in Mastodon, - `noop`: don't copy the subject.", - suggestions: ["email", "masto", "noop"] + description: "URL of the logo, defaults to Pleroma's logo", + suggestions: ["/static/logo.png"] }, %{ - key: :alwaysShowSubjectInput, - label: "Always show subject input", - type: :boolean, - description: "When disabled, auto-hide the subject field if it's empty" + key: :logoMargin, + label: "Logo margin", + type: :string, + description: + "Allows you to adjust vertical margins between logo boundary and navbar borders. " <> + "The idea is that to have logo's image without any extra margins and instead adjust them to your need in layout.", + suggestions: [".1em"] }, %{ key: :logoMask, @@ -1228,24 +1197,84 @@ config :pleroma, :config_description, [ "If you want a colorful logo you must disable logoMask." }, %{ - key: :logoMargin, - label: "Logo margin", + key: :minimalScopesMode, + label: "Minimal scopes mode", + type: :boolean, + description: + "Limit scope selection to Direct, User default, and Scope of post replying to. " <> + "Also prevents replying to a DM with a public post from PleromaFE." + }, + %{ + key: :nsfwCensorImage, + label: "NSFW Censor Image", type: :string, description: - "Allows you to adjust vertical margins between logo boundary and navbar borders. " <> - "The idea is that to have logo's image without any extra margins and instead adjust them to your need in layout.", - suggestions: [".1em"] + "URL of the image to use for hiding NSFW media attachments in the timeline.", + suggestions: ["/static/img/nsfw.74818f9.png"] + }, + %{ + key: :postContentType, + label: "Post Content Type", + type: {:dropdown, :atom}, + description: "Default post formatting option.", + suggestions: ["text/plain", "text/html", "text/markdown", "text/bbcode"] + }, + %{ + key: :redirectRootNoLogin, + label: "Redirect root no login", + type: :string, + description: + "Relative URL which indicates where to redirect when a user isn't logged in", + suggestions: ["/main/all"] + }, + %{ + key: :redirectRootLogin, + label: "Redirect root login", + type: :string, + description: + "Relative URL which indicates where to redirect when a user is logged in", + suggestions: ["/main/friends"] + }, + %{ + key: :scopeCopy, + label: "Scope copy", + type: :boolean, + description: "Copy the scope (private/unlisted/public) in replies to posts by default" + }, + %{ + key: :sidebarRight, + label: "Sidebar on Right", + type: :boolean, + description: "Change alignment of sidebar and panels to the right." }, %{ - key: :stickers, + key: :showFeaturesPanel, + label: "Show instance features panel", type: :boolean, - description: "Enables stickers." + description: + "Enables panel displaying functionality of the instance on the About page." }, %{ - key: :enableEmojiPicker, - label: "Emoji picker", + key: :showInstanceSpecificPanel, + label: "Show instance specific panel", type: :boolean, - description: "Enables emoji picker." + description: "Whether to show the instance's custom panel" + }, + %{ + key: :subjectLineBehavior, + label: "Subject line behavior", + type: :string, + description: "Allows changing the default behaviour of subject lines in replies. + `email`: copy and preprend re:, as in email, + `masto`: copy verbatim, as in Mastodon, + `noop`: don't copy the subject.", + suggestions: ["email", "masto", "noop"] + }, + %{ + key: :theme, + type: :string, + description: "Which theme to use. Available themes are defined in styles.json", + suggestions: ["pleroma-dark"] } ] }, @@ -1301,6 +1330,12 @@ config :pleroma, :config_description, [ suggestions: [ :pleroma_fox_tan ] + }, + %{ + key: :default_user_avatar, + type: :string, + description: "URL of the default user avatar.", + suggestions: ["/images/avi.png"] } ] }, @@ -1408,6 +1443,21 @@ config :pleroma, :config_description, [ } ] }, + %{ + group: :pleroma, + key: :mrf_activity_expiration, + label: "MRF Activity Expiration Policy", + type: :group, + description: "Adds expiration to all local Create Note activities", + children: [ + %{ + key: :days, + type: :integer, + description: "Default global expiration time for all local Create activities (in days)", + suggestions: [90, 365] + } + ] + }, %{ group: :pleroma, key: :mrf_subchain, @@ -1545,14 +1595,12 @@ config :pleroma, :config_description, [ # %{ # group: :pleroma, # key: :mrf_user_allowlist, - # type: :group, + # type: :map, # description: # "The keys in this section are the domain names that the policy should apply to." <> # " Each key should be assigned a list of users that should be allowed through by their ActivityPub ID", - # children: [ - # ["example.org": ["https://example.org/users/admin"]], # suggestions: [ - # ["example.org": ["https://example.org/users/admin"]] + # %{"example.org" => ["https://example.org/users/admin"]} # ] # ] # }, @@ -1574,6 +1622,31 @@ config :pleroma, :config_description, [ "The base URL to access a user-uploaded file. Useful when you want to proxy the media files via another host/CDN fronts.", suggestions: ["https://example.com"] }, + %{ + key: :invalidation, + type: :keyword, + descpiption: "", + suggestions: [ + enabled: true, + provider: Pleroma.Web.MediaProxy.Invalidation.Script + ], + children: [ + %{ + key: :enabled, + type: :boolean, + description: "Enables invalidate media cache" + }, + %{ + key: :provider, + type: :module, + description: "Module which will be used to cache purge.", + suggestions: [ + Pleroma.Web.MediaProxy.Invalidation.Script, + Pleroma.Web.MediaProxy.Invalidation.Http + ] + } + ] + }, %{ key: :proxy_opts, type: :keyword, @@ -1646,6 +1719,45 @@ config :pleroma, :config_description, [ } ] }, + %{ + group: :pleroma, + key: Pleroma.Web.MediaProxy.Invalidation.Http, + type: :group, + description: "HTTP invalidate settings", + children: [ + %{ + key: :method, + type: :atom, + description: "HTTP method of request. Default: :purge" + }, + %{ + key: :headers, + type: {:list, :tuple}, + description: "HTTP headers of request.", + suggestions: [{"x-refresh", 1}] + }, + %{ + key: :options, + type: :keyword, + description: "Request options.", + suggestions: [params: %{ts: "xxx"}] + } + ] + }, + %{ + group: :pleroma, + key: Pleroma.Web.MediaProxy.Invalidation.Script, + type: :group, + description: "Script invalidate settings", + children: [ + %{ + key: :script_path, + type: :string, + description: "Path to shell script. Which will run purge cache.", + suggestions: ["./installation/nginx-cache-purge.sh.example"] + } + ] + }, %{ group: :pleroma, key: :gopher, @@ -1855,12 +1967,6 @@ config :pleroma, :config_description, [ (see https://github.com/sorentwo/oban/issues/52). """, children: [ - %{ - key: :repo, - type: :module, - description: "Application's Ecto repo", - suggestions: [Pleroma.Repo] - }, %{ key: :verbose, type: {:dropdown, :atom}, @@ -2031,11 +2137,10 @@ config :pleroma, :config_description, [ %{ key: :parsers, type: {:list, :module}, - description: "List of Rich Media parsers.", + description: + "List of Rich Media parsers. Module names are shortened (removed leading `Pleroma.Web.RichMedia.Parsers.` part), but on adding custom module you need to use full name.", suggestions: [ - Pleroma.Web.RichMedia.Parsers.MetaTagsParser, Pleroma.Web.RichMedia.Parsers.OEmbed, - Pleroma.Web.RichMedia.Parsers.OGP, Pleroma.Web.RichMedia.Parsers.TwitterCard ] }, @@ -2043,7 +2148,8 @@ config :pleroma, :config_description, [ key: :ttl_setters, label: "TTL setters", type: {:list, :module}, - description: "List of rich media TTL setters.", + description: + "List of rich media TTL setters. Module names are shortened (removed leading `Pleroma.Web.RichMedia.Parser.` part), but on adding custom module you need to use full name.", suggestions: [ Pleroma.Web.RichMedia.Parser.TTL.AwsSignedUrl ] @@ -2633,18 +2739,6 @@ config :pleroma, :config_description, [ } ] }, - %{ - group: :http_signatures, - type: :group, - description: "HTTP Signatures settings", - children: [ - %{ - key: :adapter, - type: :module, - suggestions: [Pleroma.Signature] - } - ] - }, %{ group: :pleroma, key: :http, @@ -2717,6 +2811,8 @@ config :pleroma, :config_description, [ %{ key: :scrub_policy, type: {:list, :module}, + description: + "Module names are shortened (removed leading `Pleroma.HTML.` part), but on adding custom module you need to use full name.", suggestions: [Pleroma.HTML.Transform.MediaProxy, Pleroma.HTML.Scrubber.Default] } ] @@ -3265,5 +3361,41 @@ config :pleroma, :config_description, [ suggestions: [false] } ] + }, + %{ + group: :pleroma, + key: :mrf, + type: :group, + description: "General MRF settings", + children: [ + %{ + key: :policies, + type: [:module, {:list, :module}], + description: + "A list of MRF policies enabled. Module names are shortened (removed leading `Pleroma.Web.ActivityPub.MRF.` part), but on adding custom module you need to use full name.", + suggestions: + Generator.list_modules_in_dir( + "lib/pleroma/web/activity_pub/mrf", + "Elixir.Pleroma.Web.ActivityPub.MRF." + ) + }, + %{ + key: :transparency, + label: "MRF transparency", + type: :boolean, + description: + "Make the content of your Message Rewrite Facility settings public (via nodeinfo)" + }, + %{ + key: :transparency_exclusions, + label: "MRF transparency exclusions", + type: {:list, :string}, + description: + "Exclude specific instance names from MRF transparency. The use of the exclusions feature will be disclosed in nodeinfo as a boolean value.", + suggestions: [ + "exclusion.com" + ] + } + ] } ]