1 # This file is responsible for configuring your application
2 # and its dependencies with the aid of the Mix.Config module.
4 # This configuration file is loaded before any dependency and
5 # is restricted to this project.
8 # General application configuration
9 config :pleroma, ecto_repos: [Pleroma.Repo]
11 config :pleroma, Pleroma.Repo, types: Pleroma.PostgresTypes
13 config :pleroma, Pleroma.Captcha,
15 seconds_retained: 180,
16 method: Pleroma.Captcha.Kocaptcha
18 config :pleroma, Pleroma.Captcha.Kocaptcha, endpoint: "https://captcha.kotobank.ch"
20 # Upload configuration
21 config :pleroma, Pleroma.Upload,
22 uploader: Pleroma.Uploaders.Local,
27 config :pleroma, Pleroma.Uploaders.Local, uploads: "uploads"
29 config :pleroma, Pleroma.Uploaders.S3,
31 public_endpoint: "https://s3.amazonaws.com"
33 config :pleroma, Pleroma.Uploaders.MDII,
34 cgi: "https://mdii.sakura.ne.jp/mdii-post.cgi",
35 files: "https://mdii.sakura.ne.jp"
37 config :pleroma, :emoji, shortcode_globs: ["/emoji/custom/**/*.png"]
39 config :pleroma, :uri_schemes,
60 {Phoenix.Socket.V1.JSONSerializer, "~> 1.0.0"},
61 {Phoenix.Socket.V2.JSONSerializer, "~> 2.0.0"}
68 # Configures the endpoint
69 config :pleroma, Pleroma.Web.Endpoint,
70 url: [host: "localhost"],
75 {"/api/v1/streaming", Elixir.Pleroma.Web.MastodonAPI.WebsocketHandler, []},
76 {"/socket/websocket", Phoenix.Endpoint.CowboyWebSocket,
77 {nil, {Pleroma.Web.Endpoint, Pleroma.Web.UserSocket, websocket_config}}},
78 {:_, Plug.Adapters.Cowboy.Handler, {Pleroma.Web.Endpoint, []}}
83 secret_key_base: "aK4Abxf29xU9TTDKre9coZPUgevcVCFQJe/5xP/7Lt4BEif6idBIbjupVbOrbKxl",
84 signing_salt: "CqaoopA2",
85 render_errors: [view: Pleroma.Web.ErrorView, accepts: ~w(json)],
86 pubsub: [name: Pleroma.PubSub, adapter: Phoenix.PubSub.PG2],
87 secure_cookie_flag: true
89 # Configures Elixir's Logger
90 config :logger, :console,
91 format: "$time $metadata[$level] $message\n",
92 metadata: [:request_id]
94 config :mime, :types, %{
95 "application/xml" => ["xml"],
96 "application/xrd+xml" => ["xrd+xml"],
97 "application/jrd+json" => ["jrd+json"],
98 "application/activity+json" => ["activity+json"],
99 "application/ld+json" => ["activity+json"]
102 config :pleroma, :websub, Pleroma.Web.Websub
103 config :pleroma, :ostatus, Pleroma.Web.OStatus
104 config :pleroma, :httpoison, Pleroma.HTTP
105 config :tesla, adapter: Tesla.Adapter.Hackney
107 # Configures http settings, upstream proxy etc.
108 config :pleroma, :http, proxy_url: nil
110 config :pleroma, :instance,
112 email: "example@example.com",
113 description: "A Pleroma instance, an alternative fediverse server",
115 remote_limit: 100_000,
116 upload_limit: 16_000_000,
117 avatar_upload_limit: 2_000_000,
118 background_upload_limit: 4_000_000,
119 banner_upload_limit: 4_000_000,
120 registrations_open: true,
123 rewrite_policy: Pleroma.Web.ActivityPub.MRF.NoOpPolicy,
125 quarantined_instances: [],
126 managed_config: true,
127 static_dir: "instance/static/",
128 allowed_post_formats: [
133 finmoji_enabled: true,
134 mrf_transparency: true
136 config :pleroma, :markup,
137 # XXX - unfortunately, inline images must be enabled by default right now, because
138 # of custom emoji. Issue #275 discusses defanging that somehow.
139 allow_inline_images: true,
140 allow_headings: false,
144 Pleroma.HTML.Transform.MediaProxy,
145 Pleroma.HTML.Scrubber.Default
148 config :pleroma, :fe,
149 theme: "pleroma-dark",
150 logo: "/static/logo.png",
152 logo_margin: "0.1em",
153 background: "/static/aurora_borealis.jpg",
154 redirect_root_no_login: "/main/all",
155 redirect_root_login: "/main/friends",
156 show_instance_panel: true,
157 scope_options_enabled: false,
158 formatting_options_enabled: false,
159 collapse_message_with_subject: false,
160 hide_post_stats: false,
161 hide_user_stats: false,
163 subject_line_behavior: "email",
164 always_show_subject_input: true
166 config :pleroma, :activitypub,
168 unfollow_blocked: true,
169 outgoing_blocks: true,
170 follow_handshake_timeout: 500
172 config :pleroma, :user, deny_follow_blocked: true
174 config :pleroma, :mrf_normalize_markup, scrub_policy: Pleroma.HTML.Scrubber.Default
176 config :pleroma, :mrf_rejectnonpublic,
177 allow_followersonly: false,
180 config :pleroma, :mrf_hellthread, threshold: 10
182 config :pleroma, :mrf_simple,
185 federated_timeline_removal: [],
189 config :pleroma, :media_proxy,
191 # base_url: "https://cache.pleroma.social",
193 # inline_content_types: [] | false | true,
197 config :pleroma, :chat, enabled: true
199 config :ecto, json_library: Jason
201 config :phoenix, :format_encoders, json: Jason
203 config :pleroma, :gopher,
208 config :pleroma, :suggestions,
211 "http://vinayaka.distsn.org/cgi-bin/vinayaka-user-match-suggestions-api.cgi?{{host}}+{{user}}",
214 web: "https://vinayaka.distsn.org/?{{host}}+{{user}}"
216 config :pleroma, :http_security,
219 sts_max_age: 31_536_000,
220 ct_max_age: 2_592_000,
221 referrer_policy: "same-origin"
225 methods: ["POST", "PUT", "DELETE", "GET", "PATCH", "OPTIONS"],
230 "X-RateLimit-Remaining",
235 headers: ["Authorization", "Content-Type", "Idempotency-Key"]
237 config :pleroma, Pleroma.User,
238 restricted_nicknames: [
269 config :pleroma, Pleroma.Web.Federator, max_jobs: 50
271 config :pleroma, Pleroma.Web.Federator.RetryQueue,
277 # Import environment specific config. This must remain at the bottom
278 # of this file so it overrides the configuration defined above.
279 import_config "#{Mix.env()}.exs"