Compare commits

..

213 commits

Author SHA1 Message Date
Henry Jameson
58770d732d Merge remote-tracking branch 'origin/develop' into shigusegubu 2026-01-26 22:03:25 +02:00
Phantasm
521fc70e48 MastoAPI AccountView AccountController: Add more block/mute expiry tests 2026-01-26 20:51:36 +02:00
Phantasm
f4a8c426df MastoAPI AccountView: Readd block/mute expiry outside the relationship 2026-01-26 20:51:36 +02:00
Phantasm
6439a5b334 MastoAPI AccountView: Add mute/block expiry to the relationship key 2026-01-26 20:51:36 +02:00
Lain Soykaf
0b813b9c4a mrf(media_proxy_warming): avoid adapter-level redirects
Drop follow_redirect/force_redirect from the HTTP options used when warming MediaProxy, relying on Tesla middleware instead (Hackney redirect handling can crash behind CONNECT proxies).

Also add a regression assertion in the policy test and document the upstream Hackney issues in ReverseProxy redirect handling.
2026-01-26 20:51:36 +02:00
Lain Soykaf
029994aa75 InstanceView: Omit comment if it's empty 2026-01-26 20:51:36 +02:00
Lain Soykaf
820a4cd97c Fix OAuth registration redirect_uris array support 2026-01-26 20:51:36 +02:00
MediaFormat
ad5bb02bd6 fix tests 2026-01-26 20:51:36 +02:00
MediaFormat
cb389e788d fix field type, fix formatting 2026-01-26 20:51:36 +02:00
MediaFormat
ba280b2d0f add changelog.d entry 2026-01-26 20:51:36 +02:00
MediaFormat
861a9f9365 Change redirect_uris to accept array of strings 2026-01-26 20:51:36 +02:00
Haelwenn (lanodan) Monnier
519ef4be5e mix: upgrade vix from "~> 0.26.0" to "~> 0.36"
Dropping the last zero should allow to get 0.x updates rather
than only 0.36.x updates.

Fixes: https://git.pleroma.social/pleroma/pleroma/-/issues/3393
2026-01-26 20:51:36 +02:00
Phantasm
f6c410b06c Move LiveDashboard to /pleroma/live_dashboard 2026-01-26 20:51:35 +02:00
Phantasm
f16dad2879 Docs: Add admin documentation for LiveDashboard and Oban Web 2026-01-26 20:51:35 +02:00
Phantasm
421187dbfa Remove /pleroma/oban and /phoenix/live_dashboard from API routes
This is needed to prevent admin frontend overrides from misbehaving when
overriding AdminFE located at /pleroma/admin, since API routes are
interpreted as the first portion of their full path, ie:
/api/v1/pleroma/admin -> /api
2026-01-26 20:51:35 +02:00
Phantasm
ac6ec02725 changelog 2026-01-26 20:51:35 +02:00
Phantasm
af4bed50e6 Add Oban Web and upgrade LiveView, plug 2026-01-26 20:51:35 +02:00
Lain Soykaf
033083d1d1 Streamer: Fix Marker streaming bug, fix caching in tests. 2026-01-26 20:51:35 +02:00
Lain Soykaf
343e42126a Add changelog 2026-01-26 20:51:35 +02:00
Lain Soykaf
b2be7d48bc Mix: Silence migrations 2026-01-26 20:51:35 +02:00
Lain Soykaf
02185ec711 StripLocation, ReadDescription: Silence noisy errors. 2026-01-26 20:51:35 +02:00
Lain Soykaf
7283d4f9be Config: Make streaming in tests actually synchronous 2026-01-26 20:51:35 +02:00
Lain Soykaf
6a81e4fe00 Tests: Syncify tests that mutate global state. 2026-01-26 20:51:35 +02:00
nicole mikołajczyk
520bac27dc Add changelog entry
Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
2026-01-26 20:51:35 +02:00
nicole mikołajczyk
5068e31583 optimize follow_request_count for own account view
Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
2026-01-26 20:51:35 +02:00
floatingghost
c07506ab6e paginate follow requests (#460)
matches https://docs.joinmastodon.org/methods/follow_requests/#get mostly

Co-authored-by: FloatingGhost <hannah@coffee-and-dreams.uk>
Reviewed-on: https://akkoma.dev/AkkomaGang/akkoma/pulls/460
Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
2026-01-26 20:51:35 +02:00
Lain Soykaf
3d7d119782 Linting 2026-01-26 20:51:35 +02:00
Lain Soykaf
b013ec9123 Emoji, AccountView, UtilController: Handle encoding of emoji 2026-01-26 20:51:35 +02:00
Lain Soykaf
7ce7d4d319 Linting 2026-01-26 20:51:35 +02:00
Lain Soykaf
33b8ccf21f Emoji: Handle more edge cases for local emoji with strange filenames. 2026-01-26 20:51:35 +02:00
Lain Soykaf
b552c25039 Add changelog 2026-01-26 20:51:35 +02:00
Lain Soykaf
72fea0c901 Emoji: Unify tag building, fix tests. 2026-01-26 20:51:35 +02:00
Lain Soykaf
1085f6d7cd TransmogrifierTest: Add failing test for EmojiReact url encoding 2026-01-26 20:51:35 +02:00
Lain Soykaf
89ac0b8f0a Add changelog 2026-01-26 20:51:35 +02:00
Lain Soykaf
65456aed12 Release-to-Docker: Add unzip / curl to make updates work 2026-01-26 20:51:35 +02:00
Lain Soykaf
5600634574 Installation: Add Release-Via-Docker option 2026-01-26 20:51:35 +02:00
nicole mikołajczyk
e40bedc601 Add v1/instance/domain_blocks endpoint
Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
2026-01-26 20:51:35 +02:00
Lain Soykaf
8936066427 test(http): cover reverse proxy redirects via CONNECT proxy
Exercises Pleroma.ReverseProxy.Client.Hackney with follow_redirect enabled behind an HTTPS CONNECT proxy, ensuring the client follows a relative redirect and can stream the final body.
2026-01-26 20:51:35 +02:00
Mark Felder
71a4b8d0f2 In-house redirect handler for mediaproxy with Hackney adapter
Also ensure we always pass an absolute URL to Hackney when parsing a redirect response

(cherry picked from commit 00ac6bce8d244eec7e2460358296619e5cacba6b)
2026-01-26 20:51:35 +02:00
Lain Soykaf
f2ad6100f2 test(http): reproduce hackney follow_redirect crash via CONNECT proxy
Hackney 1.25 crashes when follow_redirect is enabled behind an HTTPS CONNECT proxy and the Location header is relative (hackney_http_connect transport).
This test demonstrates the failure and verifies Tesla-level redirects work when hackney redirects are disabled.
2026-01-26 20:51:35 +02:00
Lain Soykaf
500340fc82 test(http): cover pooled redirect with hackney
Reproduces the Hackney 1.25 pooled redirect cleanup issue which can surface as :req_not_found when the adapter returns a Ref and the body is later fetched.
2026-01-26 20:51:35 +02:00
Lain Soykaf
b85507c764 http(hackney): disable adapter redirects by default
Hackney 1.25.x has redirect handling issues behind CONNECT proxies and with pools.
Disable hackney-level redirects and rely on Tesla.Middleware.FollowRedirects instead.
Also default to with_body: true so redirects can be followed reliably.
2026-01-26 20:51:35 +02:00
lain
01d94a0135 Revert "Merge branch 'revert-cdd6df06' into 'develop'"
This reverts merge request !4411
2026-01-26 20:51:35 +02:00
Henry Jameson
8d82808d7a Merge remote-tracking branch 'origin/develop' into shigusegubu 2026-01-03 02:01:33 +02:00
Henry Jameson
baa8004a2a new styles for static pages 2025-08-12 16:55:31 +03:00
Henry Jameson
d380bdd2f9 Merge remote-tracking branch 'origin/develop' into shigusegubu 2025-08-11 09:14:40 +03:00
Henry Jameson
82a65328c2 delete custom emoji file 2025-07-10 21:42:06 +03:00
Henry Jameson
4808c9824e Merge remote-tracking branch 'origin/develop' into shigusegubu 2025-07-09 17:01:33 +03:00
Henry Jameson
63b82091d9 Merge remote-tracking branch 'origin/develop' into shigusegubu 2025-06-25 14:23:41 +03:00
Henry Jameson
7f121afaba fix 2025-03-11 22:05:16 +02:00
Henry Jameson
74cda5b78f Merge remote-tracking branch 'origin/develop' into shigusegubu 2025-03-11 22:04:42 +02:00
Henry Jameson
4e05e7a989 Merge remote-tracking branch 'origin/develop' into shigusegubu 2024-12-18 11:34:33 +02:00
Henry Jameson
77119d9368 c 2024-10-08 18:39:17 +03:00
Henry Jameson
fcfe16340a alsp 2024-10-08 18:38:43 +03:00
Henry Jameson
8b249431da Merge remote-tracking branch 'origin/develop' into shigusegubu 2024-10-08 18:01:04 +03:00
Henry Jameson
c775b4876d Merge remote-tracking branch 'origin/develop' into shigusegubu 2024-08-29 00:10:59 +03:00
Henry Jameson
bf5b097cd2 Merge remote-tracking branch 'origin/develop' into shigusegubu 2024-08-06 16:46:58 +03:00
Henry Jameson
3e1b210486 Merge remote-tracking branch 'origin/develop' into shigusegubu 2024-05-23 01:09:54 +03:00
Henry Jameson
2561febffd thanks emacs/arch 2024-03-26 12:48:52 +02:00
Henry Jameson
d65bdde809 Merge remote-tracking branch 'origin/develop' into shigusegubu 2024-03-26 12:34:10 +02:00
Henry Jameson
5a80729986 always include title, manifest and favicon 2023-11-01 18:57:20 +02:00
Henry Jameson
034189afc8 Merge branch 'favicon' into shigusegubu 2023-11-01 18:51:03 +02:00
Henry Jameson
7861ac27f2 Merge remote-tracking branch 'origin/develop' into shigusegubu 2023-11-01 18:50:58 +02:00
Henry Jameson
6f38915198 lint? 2023-10-30 11:29:57 +02:00
Henry Jameson
d8eb741b6d changelog 2023-10-29 19:32:07 +02:00
Henry Jameson
af4be5623e Merge branch 'favicon' into shigusegubu 2023-10-29 19:29:07 +02:00
Henry Jameson
3d2067d433 typo 2023-10-29 19:28:57 +02:00
Henry Jameson
7a84ae4548 Merge branch 'favicon' into shigusegubu 2023-10-29 19:25:45 +02:00
Henry Jameson
5848ef137f add fields needed for chrome to make website installable 2023-10-29 19:25:14 +02:00
Henry Jameson
b1b41e8be1 Merge branch 'favicon' into shigusegubu 2023-10-29 19:14:48 +02:00
Henry Jameson
82e4c5d077 include the PWA manifest 2023-10-29 19:13:02 +02:00
Henry Jameson
337d047c4d embed favicon on backend and make it configurable 2023-10-29 18:58:57 +02:00
Henry Jameson
a5048c270e oops 2023-09-04 19:39:51 +03:00
Henry Jameson
303db126a8 Merge remote-tracking branch 'origin/tusooa/quote' into shigusegubu 2023-09-04 19:34:06 +03:00
Henry Jameson
dd35bf93c7 Merge remote-tracking branch 'origin/develop' into shigusegubu 2023-09-04 19:30:54 +03:00
tusooa
c525496e75 Merge branch 'develop' into 'tusooa/quote'
# Conflicts:
#   lib/pleroma/constants.ex
2023-08-31 00:35:37 +00:00
Henry Jameson
78697ad23a Merge remote-tracking branch 'origin/develop' into shigusegubu 2023-07-19 21:06:02 +03:00
tusooa
bffa258a23
Fix quote_visible attribute 2023-07-13 06:56:06 -04:00
tusooa
2436c9d61d
Expose quote_id parameter on the api 2023-07-13 06:56:06 -04:00
tusooa
5ebabcd582
Do not mention original poster when quoting 2023-07-13 06:56:00 -04:00
tusooa
44eb648179
Fix config descriptions for mrf inline quote 2023-07-12 22:07:51 -04:00
tusooa
fca6a7933e
Fix TransmogrifierTest 2023-07-12 14:58:20 -04:00
tusooa
01eafc0372
Make InlineQuotePolicy history aware 2023-07-12 14:37:12 -04:00
tusooa
05beada21b
Add mrf to force link tag of quoting posts 2023-07-12 14:30:58 -04:00
tusooa
f8b01788eb
Keep incoming Link tag 2023-07-12 14:08:24 -04:00
tusooa
8f252fd99b
Parse object link as quoteUrl 2023-07-12 11:09:10 -04:00
tusooa
2c70857f9f
Allow more flexibility in InlineQuotePolicy 2023-07-12 09:30:43 -04:00
tusooa
26b499eca0
Fix CommonAPITest 2023-07-10 19:43:18 -04:00
tusooa
ebcac09f5c
Add changelog 2023-07-10 18:28:13 -04:00
tusooa
3bb384d378
Allow local quote and private self-quote 2023-07-10 18:27:23 -04:00
tusooa
44cea92fbc
Unify logic for normalizing quoteUri 2023-07-10 18:14:14 -04:00
Alex Gleason
52c81cdf68
InlineQuotePolicy: skip objects which already have an .inline-quote span 2023-07-10 17:52:10 -04:00
Alex Gleason
34cf4222c1
Actually, don't send _misskey_quote anymore 2023-07-10 17:52:10 -04:00
Alex Gleason
5df951f670
InlineQuotePolicy: improve the way Markdown quotes are displayed by other software 2023-07-10 17:52:10 -04:00
Alex Gleason
32e284ed2c
Handle Fedibird's new quoteUri field 2023-07-10 17:52:10 -04:00
Alex Gleason
f89874596e
Transmogrifier: federate quotes with _misskey_quote field 2023-07-10 17:52:10 -04:00
Alex Gleason
f8b420932e
StatusView: return quote post inside a reblog 2023-07-10 17:52:10 -04:00
Alex Gleason
1cb39bfb90
Add InlineQuotePolicy as a default MRF 2023-07-10 17:52:10 -04:00
Alex Gleason
63f8c33353
InlineQuotePolicy: don't add line breaks to markdown posts 2023-07-10 17:52:10 -04:00
Alex Gleason
029a1045d4
StatusView: add quote_visible param 2023-07-10 17:52:09 -04:00
Alex Gleason
14a26e4433
StatusView: fix quote visibility 2023-07-10 17:52:09 -04:00
Alex Gleason
6d26ce54c4
CommonAPI: disallow quoting private posts through the API 2023-07-10 17:52:09 -04:00
Alex Gleason
1a6ab18ebc
Add InlineQuotePolicy to force quote URLs inline 2023-07-10 17:52:07 -04:00
Alex Gleason
06cc4ad7fd
Scrubber.Default: allow span.quote-inline for quote post compatibility 2023-07-10 17:51:03 -04:00
Alex Gleason
a3b7c1da4f
ActivityDraft: mix format, defensive actor ID 2023-07-10 17:49:42 -04:00
Alex Gleason
cca63d707d
ActivityDraft: mention the OP of a quoted post 2023-07-10 17:49:42 -04:00
Alex Gleason
4bcdf0cf4f
Return quote_url through the API, don't render quotes more than 1 level deep 2023-07-10 17:49:42 -04:00
Alex Gleason
2f9a098dd5
@context: add quoteUrl 2023-07-10 17:49:42 -04:00
Alex Gleason
e47c6a2445
InstanceView: add "quote_posting" feature 2023-07-10 17:49:42 -04:00
Alex Gleason
72a0236c9a
Fix typos 2023-07-10 17:49:42 -04:00
Alex Gleason
57e4e43042
mix format 2023-07-10 17:49:42 -04:00
Alex Gleason
efd6d40a40
TransmogrifierTest: prepare an outgoing quote post 2023-07-10 17:49:42 -04:00
Alex Gleason
b9c10c61b7
StatusControllerTest: test creating a quote post 2023-07-10 17:49:41 -04:00
Alex Gleason
bc2ffd0c16
BuilderTest: build quote post 2023-07-10 17:49:41 -04:00
Alex Gleason
a938a96ae8
ActivityDraft: allow quoting 2023-07-10 17:49:41 -04:00
Alex Gleason
fe5b8cbe05
ActivityDraft: create quote posts 2023-07-10 17:49:41 -04:00
Alex Gleason
f95cad4603
StatusView: render the whole quoted status 2023-07-10 17:49:41 -04:00
Alex Gleason
d10408558e
StatusView: show quoted posts through the API, probably 2023-07-10 17:49:41 -04:00
Alex Gleason
5fdf4d1b1c
Transmogrifier: fix quoteUrl here too 2023-07-10 17:49:41 -04:00
Alex Gleason
f01e2d0902
Transmogrifier: fetch quoted post 2023-07-10 17:49:39 -04:00
Alex Gleason
2c17d29c4b
ObjectValidators: improve quoteUrl compatibility 2023-07-10 17:49:06 -04:00
Alex Gleason
4c90f39e14
Quote post: add fixtures 2023-07-10 17:49:06 -04:00
Alex Gleason
f39a86344c
ObjectValidators: accept "quoteUrl" field 2023-07-10 17:48:54 -04:00
Henry Jameson
00a9eae74a Merge remote-tracking branch 'origin/develop' into shigusegubu 2023-05-27 16:42:36 +03:00
Henry Jameson
ab0ddda321 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop:
  fix: append field values to bio before parsing
  Indicate in changelog that removal of crypt is breaking
  Allow custom emoji reactions: Add pleroma_custom_emoji_reactions feature, review changes
  docs: Be more explicit about the level of compatibility of OTP releases
  Remove crypt(3) support
  Allow custom emoji reactions: add test for mixed emoji react, fix credo errors
  Allow custom emoji reactions: Fix tests, mixed custom and unicode reactions
  Allow reacting with remote emoji when they exist on the post (#200)
  feat: build rel me tags with profile fields
2023-03-20 21:30:28 +02:00
Henry Jameson
ece1f7bca6 Revert "testing newer pot"
This reverts commit f72beb6c26.
2023-03-20 21:29:24 +02:00
Henry Jameson
f72beb6c26 testing newer pot 2023-03-10 00:08:08 +02:00
Henry Jameson
5f29bf2e4f Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (57 commits)
  remove static_fe pipeline for /users/:nickname/feed
  oops, remove unused import
  use scrub_html_and_truncate instead of scrub_html for feed item title
  modify Utils.scrub_html_and_truncate to take omission parameter
  format feed_view.ex
  feed eex templates: use published field from @data, not @activity.data
  fix tag feeds: remote activities might not have a summary field
  Make clear the test names
  Fix FederatorTest
  Stop oban from retrying if validating errors occur when processing incoming data
  Add the security fix to the changelog
  Sanitize filenames when uploading
  Allow with_relationships param for blocks
  Bundle frontend
  Bump version in mix project to 2.5.1
  Compose changelog for 2.5.1
  Ignores in exiftool read descriptions
  Bump crypt to v1.0.1
  Update mix.exs
  Bump linkify
  ...
2023-03-09 23:19:11 +02:00
Henry Jameson
e2eeded539 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (126 commits)
  Revert "Merge branch 'copyright-bump' into 'develop'"
  Bump copyright year
  Extract translatable strings
  mix: version 2.5.50
  mix: Release 2.5.0
  CHANGELOG: Set 2.5.0
  Git merge is not my favorite tool
  Revert "Delete report notifs when demoting from superuser"
  Update PleromaFE bundle to 2.5.0
  Make lint happy
  Use crazy hack to finally get pleroma:report notifications not visible after revoking privileges
  Update AdminFE bundle to version 2.5.0
  Extract translatable strings
  Fix TwitterCard meta tags
  Fix CommonAPI delete function to use User.privileged? instead of User.superuser?
  use to_rfc2822 instead of pub_date in tests, too
  document rss/atom fix in changelog
  modify user feed controller test to expect summary for title
  remove pub_date() -- use to_rfc2822 instead
  remove ap_id test -- the element makes the feed break
  ...
2023-01-03 20:58:13 +02:00
Henry Jameson
447bfcdb35 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (208 commits)
  Document inclusion of wasm-unsafe-eval
  Update http_security_plug.ex
  Update lib/pleroma/web/plugs/http_security_plug.ex
  try to fix ruffle on chrome
  Alter priority of Delete activities to be lowest
  Deletes do not generate notifications of any kind, so skip trying
  Object.Fetcher: Set reachable on successful fetch
  Translated using Weblate (Ukrainian)
  Added translation using Weblate (Ukrainian)
  Added translation using Weblate (Ukrainian)
  Lint
  Update config cheatsheet
  Clarify config description
  Document Oban workers getting timeouts defined
  Lint
  Define sane Oban Worker timeouts
  Clean up stale entries in mix.lock
  Document removal of Quack
  Add migration to remove Quack from ConfigDB
  Remove Quack logging backend
  ...
2022-11-18 01:38:17 +02:00
Henry Jameson
550693111e Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (115 commits)
  Change test case wording
  Use `duration` param for mute expiration duration
  Emoji: apply recommended tail call changes
  Extract translatable strings
  Emoji: split qualification variation into a module
  Add authorized_fetch_mode to description.exs
  EmojiReactValidator: use new qualification method
  Emoji: implement full-qualifier using combinations
  EmojiReactValidator: fix emoji qualification
  Revert "Merge branch 'fix/emoji-react-qualification' into 'develop'"
  Translated using Weblate (French)
  Translated using Weblate (Chinese (Simplified))
  Translated using Weblate (Chinese (Simplified))
  Translated using Weblate (Chinese (Simplified))
  Translated using Weblate (Chinese (Simplified))
  Translated using Weblate (Chinese (Simplified))
  Translated using Weblate (Chinese (Simplified))
  Translated using Weblate (Chinese (Simplified))
  Translated using Weblate (Chinese (Simplified))
  Translated using Weblate (Chinese (Simplified))
  ...
2022-08-01 14:55:02 +03:00
Henry Jameson
83e4a112b9 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop:
  Add tlsv1.3 to suggestions
  hackney adapter helper & reverse proxy client: enable TLSv1.3
  StealEmojiPolicy: fix String rejected_shortcodes
  Instruct users to run 'git pull' as the pleroma user
  Also use actor_type to determine if an account is a bot in antiFollowbotPolicy
  mix: Bump to 2.4.52 for 2.4.3 mergeback
  Skip cache when /objects or /activities is authenticated
  Allow to skip cache in Cache plug
  update sweet_xml [Security]
2022-06-07 16:02:14 +03:00
Henry Jameson
46c4d3b80f huuups 2022-04-19 18:17:41 +03:00
Henry Jameson
d08362cb30 hups 2022-04-19 18:17:25 +03:00
Henry Jameson
aa38f1da41 resolve deprecation warnings in conf 2022-04-19 18:16:30 +03:00
Henry Jameson
0613478bdb engage db congfiguration 2022-04-19 17:56:26 +03:00
Henry Jameson
31115e24c0 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (294 commits)
  Fix incorrect fallback when English is set to first language
  Fix eratic test for POST /api/pleroma/admin/reports/:id/notes
  After code review
  Support fallbacking to other languages
  Delete report notifs when demoting from superuser
  Update Caddyfile to Caddy v2
  Lint
  Support multiple locales from userLanguage cookie
  Support multiple locales formally
  Make lint happy
  Add test for fallbacking to a general language
  Fallback to a variant if the language in general is not supported
  Add changelog
  Document API addition
  Allow user to register with custom language
  Allow update_credentials to update User.language
  Send emails i18n'd using backend-stored user language
  Make all emails translatable
  Fix digest test
  Make mail and mailer translatable
  ...
2022-04-19 14:27:21 +03:00
Henry Jameson
d860aa32f7 revert to default CSP for testing 2022-04-06 11:16:53 +03:00
Henry Jameson
9916734b76 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (33 commits)
  maybe_notify_subscribers: Don't create notifications from ingested messages
  TwitterAPI: Make change_email require body params instead of query
  TwitterAPI: Make change_password require body params instead of query
  Make the OPT recomendation clearer
  ObjectAgePolicy: Fix pattern matching on published
  fix: stream out Create Activity
  Improve readability
  Quarantine placeholders
  improve changelog entry
  Make transparency_exclusions use tuples in admin-fe
  Add key- and valuePlaceholders for quarantined_instances and mrf_simple
  Add transparency_exclusions also to the breaking changes
  Change docs
  quarantine instances info
  Change what nodeinfo returns without breaking backwards compatibility
  Return maps in node_info
  Add database migrations
  Fixed deprecation warning checks
  config/description.exs: Update quarantine settings to tuples
  make linter happy
  ...
2021-08-11 21:56:37 +03:00
Henry Jameson
78c21efa1e Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (252 commits)
  mix.exs: 2.4.50
  Update PleromaFE Bundle (2.4.0)
  CHANGELOG.md: Fix instances of 2020 being actually 2021
  Release 2.4.0
  Update AdminFE bundle
  Visibility: check Tombstone objects in visible_for_user?/2
  CHANGELOG: fixed JSON error rendering
  Add activity+json to Phoenix :format_encoders Fixes ErrorView rendering
  CHANGELOG: AdminAPI return date with users
  AdminAPI: add date to users
  CHANGELOG: AdminAPI users sort
  AdminAPI: sort user results by ID descending
  Moderators: reorganize :admin_api pipeline in Router
  Moderators: add UserIsStaffPlug
  AP C2S: Remove restrictions and make it go through pipeline
  Update Linkify to fix crash on posts with a URL we failed to parse correctly
  fix the fucking list timelines on mastofe/soapbox-fe
  Deletions: change User.purge/1 to defp, add CHANGELOG entry
  Deletions: don't purge keys so Delete/Undo activities can be signed
  Deletions: allow deactivated users to be deleted
  ...
2021-08-08 17:59:23 +03:00
Henry Jameson
a756ec71a7 try to fix ruffle on chrome 2021-04-12 00:45:03 +03:00
Henry Jameson
a5fab1c8af Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (159 commits)
  Fix CHANGELOG entry meant for next release
  Revert "Merge branch 'patch-fix-open-api-spec' into 'develop'"
  object_validator: Refactor most of validate/2 to a generic block
  date-times are always strings
  Fix function calls due to module name change
  Temp file leaked, oops
  Add more details to the cheatsheat for FollowBot MRF
  Prefer FollowBot naming convention vs Followbot
  Document new FollowBot MRF
  More tests to validate Followbot is behaving
  Remove Task.async as it is broken here and probably a premature optimization anyway
  Only need to validate a follow request is generated for now
  Revert
  Do not try to follow local users. Their posts are already available locally on the instance.
  Change module name to FollowbotPolicy
  Add follow_requests_outstanding_since?/3 to Pleroma.Activity
  Lint
  Better checking of previous follow request attempts
  Prevent duplicates from being processed
  Make the followbot only dispatch follow requests once per 30 day period
  ...
2021-04-05 02:46:35 +03:00
Henry Jameson
e7aebdf7b6 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (185 commits)
  OAuthScopesPlug: remove transform_scopes in favor of explicit admin scope definitions
  OpenAPI: Add `admin:` scope prefix to admin operations
  Remove `:auth, :enforce_oauth_admin_scope_usage`
  Do not want these interfering with develop builds
  Make it possible to generate custom docker images by prefixing the branch name with "build-docker"
  Chats: Introduce /api/v2/pleroma/chats which implements pagination
  ChatMessage schema: Add `unread` property
  Relicense documentation under CC-BY-4.0
  Add API endpoint to remove a conversation
  update changelog to mention change of avatar
  replace avi.png
  Add myself to .mailmap
  [#2053] Changed `Notification/for_user_query/2` to use join to filter out inactive actors instead of subselect of _all_ inactive AP ids from `users`.
  [#2510] Improved support for app-bound OAuth tokens. Auth-related refactoring.
  not used mock
  OpenAPI spec: Do not show build enviroment in the spec version
  OpenAPI spec task: Load pleroma application to get version info
  Lint
  Revert "Add plaintext support for all emails except the digest"
  MRF NoEmptyPolicy: Deny posts from local users if there is no content or only mentions.
  ...
2021-02-20 20:47:18 +02:00
Henry Jameson
697397e2b8 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (145 commits)
  CHANGELOG.md: Remove wrong entries from Unreleased(patch)
  Only run one attachment cleanup job per node
  Just validate command is in PATH; forking a shell is wasteful
  Linting.
  Pbkdf2: Use it everywhere.
  Password -> Password.Pbkdf2
  Linting
  Password: Replace Pbkdf2 with Password.
  Password: Add password module
  COPYING: Bump copyright to 2021
  Bump Copyright to 2021
  Pagination: Don't be dos'd by random parameters.
  Simplify. We will always have a result from Upload.base_url/0, so just add it to the list
  Fix regression in MediaProxy.local?/0 and appending the Upload.base_url to whitelisted domains
  ChatMessages: Fix pagination headers.
  Formatting
  .formatter.exs: Format optional migrations
  Add development section
  Apply 4 suggestion(s) to 2 file(s)
  Move construction of S3 base URL with optional namespace and bucket to Upload.base_url/0
  ...
2021-01-18 04:04:27 +02:00
Henry Jameson
d5afe8a884 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (330 commits)
  Translated using Weblate (Chinese (Simplified))
  Minor refactoring of the logic for hiding followers/following counts.
  changelog
  Fix for dropping posts/notifs in WS when mix task is executed
  Fixed Rich Media Previews
  Majic: specify commit so source users do not get surprise updates
  Switch to a fork of Hackney 1.15.2 for now so we can have our URL normalization bugfix
  instance.gen: Warn that stripping exif requires exiftool
  instance.gen task: Only show files which will be actually overwritten
  Translated using Weblate (Ukrainian)
  Added translation using Weblate (Ukrainian)
  Tweaks to OAuth entities expiration: changed default to 30 days, removed hardcoded values usage, fixed OAuthView (expires_in).
  Changed default OAuth token expiration time to 30 days.
  [#3112] .gitattributes fix.
  Update CHANGELOG
  ApplicationRequirements: Add test, more text for pool size.
  Apply 1 suggestion(s) to 1 file(s)
  Add a startup error for modified Repo pool_size
  instance.reachable?: Limit to binary input
  instance: Do not fetch unreachable instances
  ...
2020-12-17 11:27:54 +02:00
Henry Jameson
1f3c8cf707 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (162 commits)
  Improve Keyword descriptions for AdminFE
  Fixed User.is_discoverable attribute rendering in Admin API User view.
  @doc fix.
  FrontStatic plug: excluded invalid url
  phoenix_controller_render_duration is no longer available in telemetry of Phoenix 1.5+
  ActivityPub: Add back debug call + explanation.
  clients.md: Add AndStatus, note supported protocols
  Fix link reference
  NoNewPrivileges breaks ability to send email via sendmail because it restricts ability to run setuid/setgid binaries
  Changelog: Add info about whitespace name remote users.
  User: Correctly handle whitespace names.
  Translated using Weblate (Chinese (Simplified))
  [#3059] Used forked prometheus-phx to remove log spam.
  [#3059] Formatting fix.
  [#3059] Fixed Phoenix 1.5 telemetry processing.
  Changelog: Add information about self-chats
  SideEffects: Correctly handle chat messages sent to yourself
  fix module name
  update changelog
  update docs
  ...
2020-10-30 02:04:07 +02:00
Henry Jameson
5f23876552 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (180 commits)
  Deep link to the user account in AdminFE in account confirmation emails
  Spelling
  Ask user to use matching values for database setup
  Syntax error
  Don't always need to drop
  Improve backup/restore documentation
  Lint
  Apply 1 suggestion(s) to 1 file(s)
  Apply 1 suggestion(s) to 1 file(s)
  Apply 2 suggestion(s) to 2 file(s)
  Improve description yet again
  Don't leak internal variables in the docs. They're useless to users.
  Credo
  Improve descriptions for reserved and proxies
  Add test for an entry without CIDR format
  Move hardcoded default configuration into config.exs
  Fix docs for default headers used by RemoteIp. We only use X-Forwarded-For by default.
  Document the NSFW link preview change
  Add helper function to convert single IPs into CIDR format if they were not provided that way
  Docs: Modify docs so the postgres config is harder to get wrong.
  ...
2020-10-11 21:13:29 +03:00
Henry Jameson
461c465fe7 fix filenameposting 2020-09-18 13:39:01 +03:00
Henry Jameson
4174bc6126 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (566 commits)
  Fix MRF reject for ChatMessage
  Create MRF.filter_pipeline to inject :object_data when present
  KeywordPolicy: Still match when fields are absent
  pleroma-fe bundle: bump to b225c3578f3c89af5ed3a0be3f8f3a6bbcedcc7d
  CHANGELOG.md: Add 2.1.2 entry
  mix.exs: bump version to 2.1.2
  Merge branch '2130-mfa-users-oauth-login-fix' into 'develop'
  Merge branch 'fix/streaming-termination-errors' into 'develop'
  Merge branch 'fix/mrf-simple-welcome-chats' into 'develop'
  Merge branch 'reply-visibility-user-guard' into 'develop'
  Merge branch 'bugfix/mrf-ingestion' into 'develop'
  adapt to new user factory behavior
  add test and changelog entry
  User search respect discoverable flag
  Merge branch 'hotfix/rich-media-compile-error' into 'develop'
  Merge branch 'feat/rich-media-head' into 'develop'
  Deny ConfigDB migration when deprecated settings found
  RichMedia: Fix log spam on failures and resetting TTL on cached errors
  Return the file content for `GET /api/pleroma/admin/instance_document/:document_name`
  add description to changelog
  ...
2020-09-17 23:40:53 +03:00
Henry Jameson
605d542a7c Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (67 commits)
  Fix example json response
  ChatMessage schema: Add preview cards.
  ChatMessageReferenceView: Display preview cards.
  OTP users need Pleroma running to execute pleroma_ctl, so reorganize instructions.
  Attempt to fix markdown formatting
  Apply 1 suggestion(s) to 1 file(s)
  set versions
  updated `cors_plug`
  set `postgrex` version
  set `web_push_encryption` version
  updated `calendar` package
  Expose seconds_valid in Pleroma Captcha API endpoint
  :show_reactions, refactor the other test
  :show_reactions, add CHANGELOG.md, refactor test
  feed/user_controller: Return 404 when the user is remote
  AccountController: Don't explicitly ask to keep users unconfirmed.
  EnsureRePrepended: Don't break on chat messages.
  update mogrify package
  set http_signatures version
  set `jason` version
  ...
2020-07-31 11:31:21 +03:00
Henry Jameson
6d93391dee power time 2020-07-31 11:29:52 +03:00
Henry Jameson
34272773b0 important shit 2020-07-28 21:51:59 +03:00
Henry Jameson
080416f175 demilitarize 2020-07-27 22:09:52 +03:00
Henry Jameson
e131678d69 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (213 commits)
  Apply 1 suggestion(s) to 1 file(s)
  ReverseProxy tesla client: remove handling of old_conn
  ReverseProxy: Fix a gun connection leak when there is an error with no body
  OpenAPI: remove accidentally pasted buffer data
  OpenAPI: Replace actor_id by account_id to follow ChatMessage schema
  Update types in Pleroma.Formatter group
  added migrate old settings to new
  Ensure Oban is available during mix tasks. Fixes: mix pleroma.user rm username
  Fix mix tasks that make HTTP calls by starting the Gun connection pool
  remove duplicate module
  Support blocking via query parameters as well and document the change.
  [#2791] AccountView: renamed `:force` option to `:skip_visibility_check`.
  added warning to use old keys
  Update linkify migration tests to use config from ConfigDB
  Migration to fix malformed Pleroma.Formatter config
  Refactor require_migration/1 into a test helper function
  Add AutolinkerToLinkify migration test
  Fix linkify ConfigDB migration
  [#1973] Fixed accounts rendering in GET /api/v1/pleroma/chats with truish :restrict_unauthenticated. Made `Pleroma.Web.MastodonAPI.AccountView.render("show.json", _)` demand :for or :force option in order to prevent incorrect rendering of empty map instead of expected user representation with truish :restrict_unauthenticated setting.
  Add related_policy field
  ...
2020-07-27 22:08:27 +03:00
Henry Jameson
0e72fdac6e Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (164 commits)
  [#1895] credo fix.
  [#1895] Applied code review suggestion.
  [#1895] Documentation hints on private instances and instance/restrict_unauthenticated setting.
  [#1895] Made hashtag timeline respect `:restrict_unauthenticated` instance setting.
  Add "Bot" to User Agent to coerce Twitter into serving OGP <meta> tags.
  Update frontend
  Changelog: Add info about avatar removal
  AccountController: Remove unused `update_?` routes.
  Docs: Document resetting of images
  AccountController: Allow removal / reset of user images.
  Fix getting videos from peertube
  added hyper:// to default protocols
  Config: Remove Statusnet preloader.
  Preloaders: Remove status_net preloader
  Update frontend
  Update frontend
  StaticFE Plug: Use phoenix helper to get the requested format.
  Changelog: Document description limits.
  Docs: document instance differences
  InstanceView: Add chat limit, description limit
  ...
2020-07-08 20:11:33 +03:00
Henry Jameson
593edd3c41 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (53 commits)
  Add warning against parsing/reusing MastoFE settings blob
  Update NotificationOperation spec
  Add `is_muted` to notifications
  Translated using Weblate (Italian)
  Added translation using Weblate (Italian)
  Add include for the "Further reading" section
  HellthreadPolicy: Restrict to Notes and Articles.
  Apply suggestion to lib/pleroma/web/api_spec/operations/pleroma_emoji_pack_operation.ex
  proper error codes for error in adminFE
  Apply suggestion to lib/pleroma/web/api_spec/operations/pleroma_emoji_pack_operation.ex
  cheatsheet.md: no_attachment_links → attachment_links
  fix for packs pagination
  Stop filling conversation field on incoming objects (legacy, unused)
  Only accounts with Service actor_type are considered as bots
  Add support for bot field in update_credentials
  README: Add some troubleshooting info for compilation issues.
  [#1873] Fixes missing :offset pagination param support. Added pagination support for hashtags search.
  default page size for files
  changelog entry
  adding overall count for packs and files
  ...
2020-06-23 01:35:40 +03:00
Henry Jameson
ce6f690a85 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (276 commits)
  Remove `poll` from `notification_type` OpenAPI spec
  credo fix
  CHANGELOG.md: mention minimal elixir version update
  Update OTP releases to official images of 1.10.3
  Chunk the notification type backfill migration
  moving custom ecto types in context folders
  Upgrade to Elixir 1.9
  naming
  fix attemps to merge map
  fix for updated hackney
  Mogrify args as custom tuples
  Fix tests
  Changelog: Add info about conversation view changes.
  Conversations: Return last dm for conversation, not last message.
  Mastodon API: ensure the notification endpoint doesn't return less than the requested amount of records unless it's the last page
  ControllerHelper: Always return id field.
  Apply suggestion to lib/pleroma/web/controller_helper.ex
  Remove use of atoms in MRF.UserAllowListPolicy
  Fix atom leak in Rich Media Parser
  Return an empty map from Pleroma.Web.RichMedia.Parsers.OGP.parse/2
  ...
2020-06-19 15:17:00 +03:00
Henry Jameson
aba9162994 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop:
  Update AdminFE build, re-enables emoji packs
  Migrations: Make user_id index on notifications better for query.
  Notification: Actually preload objects.
  ActivityPub: Change ordering to `nulls last` in favorites query
  Activity.Queries: Use correct actor restriction.
  Migrations: Add index on client_id and client_secret for apps.
  Config: Restore old new background image
  Fix Oban warnings
  Mastodon API Controllers: Use the correct params for rate limiting.
  [#1501] Made user feed contain public and unlisted activities.
  Skip failing `:crypt` test on mac
  Docs: sql -> SQL
  Apply suggestion to docs/installation/otp_en.md
  Docs: Document reasonable Postgres settings.
  Transmogrifier: Use a simpler way to get mentions.
  User: Change signature of get_users_from_set
  StealEmojiPolicyTest: Fix flaky test.
  Factory: Set users to be ap_enabled by default.
  UserTest: Add test for user refreshing.
  User: Don't error out if we want to refresh a user but can't
2020-05-28 00:45:54 +03:00
Henry Jameson
b30d2ed0e6 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop:
  StealEmojiPolicyTest: Clean up.
  StealEmojiPolicyTest: Fix flaky test.
  Add Changelog
  OStatusController: Add Mastodon activity compat route.
  ActivityPubController: Add Mastodon activity compat route.
  OStatusController: Add Mastodon compatibility route for objects.
  ActivityPubController: Add Mastodon compatibility route.
  Add OpenAPI spec for AdminAPI.StatusController
  Move status actions to AdminAPI.StatusController
2020-05-25 17:32:13 +03:00
Henry Jameson
8676f39421 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop:
  Apply suggestion to lib/pleroma/web/common_api/utils.ex
  Update CHANGELOG and docs
  Add filename_display_max_length config
  priv/static: Add a warning discouraging admins from modifying the static files directly
  Fix notifications mark as read API
  EmojiReactionController: Return more appropriate error.
  Credo fixes for the credo god.
  AnnounceValidator: Check for announcability
  Credo fixes.
  Announcements: Fix all tests.
  SideEffects: Builed out Announce effects.
  Pipeline: Don't federate if federation is disabled.
  Announcements: Handle through common pipeline.
  CommonAPI: Change public->private implicit addressing.
  AnnounceValidator: Validate for existing announce
  ObjectValidators: Add basic Announce validator.
  TransmogrifierTest: Fix tests.
  Transmogrifier Test: Extract Announce handling.
2020-05-23 02:33:15 +03:00
Henry Jameson
f20479ded8 fix 2020-05-22 00:37:24 +03:00
Henry Jameson
2a06b66daf fix 2020-05-22 00:33:59 +03:00
Henry Jameson
f9b13c754c Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (269 commits)
  Apply suggestion to docs/administration/CLI_tasks/user.md
  rename mix task: `pleroma.user unsubscribe` -> `pleroma.user deactivate`
  Added the ability to upload background, logo, default user avatar, instance thumbnail, and the NSFW hiding image via AdminFE
  fixed `mix pleroma.instance gen`
  Also add new sidebarRight setting
  Add `background_image` to `InstanceOperation`
  Move notification actions to PleromaAPI.NotificationController
  Move conversation actions to PleromaAPI.ConversationController
  Move reaction actions to EmojiReactionController
  Add OpenAPI spec for PleromaAPI.PleromaAPIController
  Changelog: Add background to instance
  Docs: Add background_image in instance
  InstanceOperation: Add background image to example
  MastoFE: update to bundle-2020-05-20
  Apply suggestion to installation/nginx-cache-purge.sh.example
  update purge script
  Synchronize :fe settings in config.exs
  Fix summary
  User.Query: Remove superfluous `distinct`
  UserTest: Hide warning in tests.
  ...
2020-05-22 00:29:15 +03:00
Henry Jameson
74db8f4769 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (381 commits)
  CHANGELOG.md: Add entry for re-registration ban
  Reword changelog entry for follow relationship bug
  Mastodon API: do not create a following relationship if the corresponding follow request doesn't exist when calling `POST /api/v1/follow_requests/:id/authorize`
  Deactivate local users on deletion instead of deleting the record
  [#1732] Made AP C2S :followers and :following endpoints serve on no auth (as for related :api pipeline endpoints).
  PleromaFE bundle supporting follow request notifications. 5f90b6a384
  static-fe.css: Restore and move to /priv/static/static-fe
  OpenAPI: Add `follow_request` to notification types
  Fix sporadic test compilation failure caused by unused alias
  OpenAPI: Remove max pagination limit from the spec
  Updated PleromaFE bundle to prevent notifications loading issue due to unsupported parameter (`with_move`).
  MappedSignatureToIdentityPlug: Fix.
  Signature: Handle non-ap ids in key ids.
  Made follow request notifications non-optional (removed config switch).
  Increase tests on AP C2S
  Dismiss the follow request notification on rejection
  fix for auth check
  docs update
  docs fix
  list of options for pack metadata
  ...
2020-05-02 20:03:41 +03:00
Henry Jameson
5ca35e1251 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (249 commits)
  Add a test for accounts/update_credentials
  Fix activity deletion
  Add emoji support in statuses in staticfe
  AccountView: fix for other forms of <br> in bio
  Mastodon API Account view: Remove an outdated hack
  Improved in-test `clear_config/n` applicability (setup / setup_all / in-test usage).
  restrict_unauthenticated setting
  include_types parameter in /api/v1/notifications
  remove federated testing
  Improved in-test config management functions.
  Fix ssl option on Ecto config breaking release
  Admin API: `PATCH /api/pleroma/admin/users/:nickname/credentials`, `GET /api/pleroma/admin/users/:nickname/credentials`.
  Admin API: `PATCH /api/pleroma/admin/users/:nickname/change_password`
  removing with_move parameter
  Improve documentation of mrf_object_age
  gitlab: create templates for bug reports and release MRs
  warnings fix
  removing from descriptions.exs deprecated settings
  fix for content-type header for tag feed
  adding rss for user feed
  ...
2020-03-25 17:37:53 +02:00
Henry Jameson
dfad261302 fix bullshit new default 2020-02-29 15:22:32 +02:00
Henry Jameson
eb00fea508 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (116 commits)
  streamer group & Oban crontab child
  Update PleromaFE bundle for the 2.0 release
  Update AdminFE build
  add confirm field to filtered params
  Admin API: Exclude boosts from `GET /api/pleroma/admin/users/:nickname/statuses` and `GET /api/pleroma/admin/instance/:instance/statuses`
  Admin API: `GET /api/pleroma/admin/statuses` - list all statuses (accepts `godmode` and `local_only`)
  unnecessary groups
  instance.gen task: make example instance name less confusing
  instance.gen task: remind to transfer the config to the database after migrations
  instance.gen task: make instance name default to the domain
  Update AdminFE build
  Fix Dialyzer warnings
  Add a test to ensure OAuth tokens are tied to Push subscriptions
  compile fix
  instance.gen task: fix crash when using custom static directory
  Admin API: `GET /api/pleroma/admin/stats` to get status count by visibility scope
  DOCS Theming your instance
  Captcha: return invalid when answer_data is nil
  captcha_test.exs: Use the same testing logic in Kocaptcha and native
  Add missing invites_enabled and account_activation_required settings
  ...
2020-02-29 15:19:33 +02:00
Henry Jameson
239f4d56bd update MRF 2020-02-09 21:30:43 +02:00
Henry Jameson
192426b485 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (63 commits)
  Fix email mix task on OTP releases
  Actually fix upload limit on OTP releases
  Questions: Add timezone to `closed` property
  deps: update plug to 1.9
  Add User.get_follow_state/2
  fix
  EmojiReactions: Rename to EmojiReacts
  Update FE bundle
  Update CHANGELOG
  Cancellation of a follow request for a remote user
  Simplify in-database config docs
  description change
  dropdown type
  removing confusing error
  Apply suggestion to CHANGELOG.md
  removing migrate_from_db endpoint from admin api
  Remove AutoLinker `scheme` option from the config
  Add support for cancellation of a follow request
  Add cheatsheet entry
  fix not being able to pin polls
  ...
2020-02-09 21:28:21 +02:00
Henry Jameson
43ea736c37 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (466 commits)
  Fix compatibility with Elixir v1.10
  Add test for custom base_url when deleting an attachment
  Fix base_url string trimming
  Add logging
  Remove `whole_db` parameter everywhere, it's not used anymore
  Fix __MODULE__ usage
  DOCS General update for the "Introduction to Pleroma" section
  update ecto
  Remove unused var
  explicitly describe perform op in AttachmentsClenupWorker
  Remove user recommendation by third party engine
  little fixes
  Fix typo
  description typos, Oban verbose type fix, new keys
  can be changed in runtime
  respect settings from database in mix tasks
  Document dynamic_configuration breaking change
  Emoji reactions: Update docs and changelog
  Emoji reactions: Change api format once more
  fix for non existing atom
  ...
2020-01-28 18:07:04 +02:00
Henry Jameson
830e18a702 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (734 commits)
  update fast sanitize dependency
  streamer: use direct object for filter checks when there is no valid child object in an activity
  Bump fast_sanitize version
  Fix moderation log crash
  Undo dialyzer fix
  Fix count
  AdminAPI: Omit relay user from users list
  Fix "the call ... will never return" warning
  Bump fast_sanitize dependency so this builds on more than just Linux
  Remove following column from the migrations
  Update test for get_recipients_from_activity
  Fix bookmark migration using a query with a schema
  Add a migration to fix blocked follows
  Fix duplicate recipients
  Rip out the rest of htmlsanitizeex
  Remove commented-out code
  Fix XSS emoji test
  Bump fast_sanitize dependency
  Fix two migrations sharing the same module name
  Migrate missing follow requests
  ...
2019-11-04 11:43:40 +02:00
Henry Jameson
0dd79c283c Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (59 commits)
  Fix OAuth cleanup worker unconditionally starting
  Parallelize template rendering
  Collect stats immediately after init
  Cache follow state
  Add a task to benchmark timeline rendering
  html.ex: Allow sub and sup elements by default
  Apply suggestion to lib/pleroma/web/activity_pub/publisher.ex
  activitypub: publisher: add (request-target) to http signature when POSTing
  MRF: fix up unserializable option lists in describe implementations
  fix formatting
  Implement Pleroma.Stats as GenServer
  streamline Streamer pings
  Isolate OAuth.Token.CleanWorker
  use default child_specs
  Conversations: Load relations in one query.
  Switch to pre-1.8 version of tzdata.
  Conversation: Render new participation on update.
  Conversations: Use correct oauth paths for extended api.
  update changelog to cover MRF describe API.
  Preload thread mutes/bookmarks in user_statuses
  ...
2019-08-17 12:12:32 +03:00
Henry Jameson
c8b2534245 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (302 commits)
  MRF: ensure that subdomain_match calls are case-insensitive
  Strip internal fields including likes from incoming and outgoing activities
  tests for Pleroma.Uploaders
  Mastodon API: Fix thread mute detection
  Uploader.S3 added support stream uploads
  Mastodon API: Set follower/following counters to 0 when hiding followers/following is enabled
  Return profile URL in MastodonAPI's `url` field
  Simplify logic to mention.js `url` field
  Return profile URL when available instead of actor URI for MastodonAPI mention URL
  Do not rembed the object after updating it
  OStatus tests: stop relying on embedded objects
  ActivityPub tests: remove assertions of embedded object being updated, because the objects are no longer supposed to be embedded
  OStatus Announce Representer: Do not depend on the object being embedded in the Create activity
  Stop depending on the embedded object in restrict_favorited_by
  [#1150] fixed parser TwitterCard
  tests for CommonApi/Utils
  Remove Reply-To from report emails
  Do not add the "next" key to likes.json if there is no more items
  Replace "impode" with "implode" for
  Remove longfox emoji set
  ...
2019-08-11 16:58:09 +03:00
Henry Jameson
ae4d15503b Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (159 commits)
  [#1043] fix search accounts.
  tasks/pleroma/instance.ex: Change :upload_dir to :uploads_dir
  Expose `skip_thread_containment` in nodeinfo
  Split alters rather than work with indexes
  Use fallback values for search queries
  Fix migration
  [#1048] Fixed version parsing in pleroma_ctl. Closes #1036.
  [#1048] Resolved violations of SemVer version format. Refactoring.
  Add fallback value to the admin report view.
  Move changelog entries
  [#1033] Fix database migrations
  Update changelog and admin API docs with tags, display_name, avatar additions
  OTP Release install docs: Remove --dry-run in cron certbot command
  Add hashtag filter to user statuses (GET /api/v1/accounts/:id/statuses)
  [#1026] Filter.AnonymizeFilename added ability to retain file extension with custom text
  Fix not being able to pin unlisted posts
  Add PLEROMA_BUILD_ENV to override env for the version generator and use it in the CI for building docs
  Add a caveat for docker deployment in the config docs
  Revert "Build releases only on tags or develop"
  Build releases only on tags or develop
  ...
2019-07-06 21:54:28 +03:00
Henry Jameson
2faac1cc48 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (36 commits)
  [#570] add user:notification stream
  fix for new instances
  no print version to the shell
  OEmbed.OEmbedController does not exist in the Pleroma codebase. It was removed in commit 92c5640f and this leftover artifact breaks compiling now.
  Update Phoenix to 1.4.8
  Apply suggestion to CHANGELOG.md
  Documentation: Document chat token response.
  Changelog: Document chat token.
  Mastodon API: Return the token needed for the chat.
  bugfix
  little fix
  version generation
  it is changed in compile time
  Fix rate limit test
  [#948] /api/v1/account_search added optional parameters (limit, offset, following)
  Fix hashtags being picked up by rich media parser
  Add copyright info to containment.ex
  Mastodon API: Document changes.
  MastodonAPI: Add a way to update the background image.
  Improve rate limiter documentation
  ...
2019-06-16 14:25:39 +03:00
Henry Jameson
f0e2fb1609 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (193 commits)
  Remove search result order for non-RUM indexes
  Update `auto_linker` dependency
  Document TagPolicy in `rewrite_policy` section
  Import release config from env variable or /etc/pleroma/config.exs and warn if the file is missing
  Add option to restrict all users to local content
  Better default parameters for suggestion
  Update `plug` dependency
  Update `ex_rated` dependency
  Replace `MastodonAPIController.account_register/2` rate limiter
  Update CHANGELOG
  Add rate limiting for search endpoints
  Add RateLimiter
  Remove unused imports and aliases from migration
  Update pleroma_ctl
  Add more tests for using media_proxy and whitelists
  Add a changelog entry for releases
  specify that a version is needed for rollback
  Add migrate/rollback to release tasks
  Fix wrong placement of serve_endpoints
  Use Mix.shell().yes? if available
  ...
2019-06-12 22:20:20 +03:00
Henry Jameson
e7ff752c52 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (218 commits)
  http: bump connection timeout to 10 seconds
  Fix prometheus-ecto error when not configured
  Document MRF.Simple :report_removal
  Add virtual :thread_muted? field
  Move default mascot configuration to `config/`
  Add changelog entry for mascot config
  Use string map for default mascot
  Format mascot tests
  Add mascot get/set tests
  Add API endpoints for a custom user mascot
  Add report filtering to MRF.SimplePolicy
  add Changelog entry
  also suppress link previews from posts marked #nsfw
  add CHANGELOG entry
  config: make sending the user agent configurable, disable sending the user agent in tests
  http: request builder: send user-agent when making requests
  rich media: suppress link previews if post is marked as sensitive
  mrf: simple policy: mark all posts instead of posts with media as sensitive if they match media_nsfw
  CI: Use the correct image with the correct hostname.
  RUM: Set rum status by the environment.
  ...
2019-05-22 00:02:44 +03:00
Henry Jameson
733b53748c more mrf 2019-05-05 23:57:11 +03:00
Henry Jameson
a506b7e1d7 undo priv_sid hacks 2019-05-04 15:28:27 +03:00
Henry Jameson
232dd79341 updates 2019-04-28 18:32:58 +03:00
Henry Jameson
10d743e46a Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop:
  Fix bookmarks depending on embeded object and move checking if the status is bookmarked to SQL
  update pleroma frontend
  tests: fix up for changed bbcode library output and verify html is properly escaped
  add support for bbcode
  mix: add bbcode dependency
  update Changelog
  Add mediaproxy whitelist capability
  Move settings to Source subentity
  test fixes
  fixes for tests
  migration without using old field name
  unused
  removing useless transaction
  migration optimization
  changelog file update
  favourites add bookmark display
  migrate user.bookmarks to separate table
  bookmarks in separate table
  activitypub: transmogrifier: send reject follow if following does not succeed
  Fix leaking private configuration parameters in Mastodon and Twitter APIs, and add new configuration parameters to Mastodon API
2019-04-28 18:29:15 +03:00
Henry Jameson
5015d517d0 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (184 commits)
  html: lock down allowed class attributes to only those related to microformats
  Extend Mastodon API with public endpoint for getting Favorites timeline of any user (#789)
  Add :emoji settings to config.md
  added healthcheck setting to instance config
  Add shortcode_globs setting to documentation
  Add a changelog entry for `pleroma.in_reply_to_account_acct`
  Add `pleroma.in_reply_to_account_acct` to MastoAPI status entity
  Replace Object.normalize(activity.data[object] with Object.normalize(acitivty) to benefit from preloading
  Fix unclosed ` and put synopsis into a code block in pleroma.emoji mix task docs
  Use `User.get_cached*` everywhere
  Feature/826 healthcheck endpoint
  Fix emoji.txt / custom_emoji.txt / shortcode_globs handling
  Formatting
  Change the default manifest to pleroma's namespace
  Replace MD5 with SHA256 for emoji pack verification
  Wrap the docstrings to 70 characters
  differences_in_mastoapi_responses.md: `content_type` parameter of post submission
  [#923] Refactored OAuthController#authorize definitions, added test.
  Set correct values in the MastoAPI reblog status view
  Mention Mastodon 2.8+ follow import fix in changelog
  ...
2019-04-24 02:38:41 +03:00
Henry Jameson
217efb4ce0 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (36 commits)
  update the follower count when a follower is blocked
  adding language tag
  AdminApiControllerTest unused variables fix.
  [#923] Removed <br> elements from auth forms, adjusted docs, minor auth settings refactoring.
  Add scheduler for sending scheduled activities to the queue
  Added limits and media attachments for scheduled activities.
  Handle `scheduled_at` on status creation.
  Add scheduled activities
  fix credo
  Use PleromaJobQueue in Pleroma.Web.Push
  [#923] OAuth consumer mode refactoring, new tests, tests adjustments, readme.
  [#923] OAuthController#callback adjustments (with tests).
  [#923] OAuth consumer controller tests. Misc. improvements.
  Improve Transmogrifier.upgrade_user_from_ap_id/2
  second level of headertext change in doc
  syntax highlighting
  test fix
  little changes and typos
  updating custom_emoji docs
  refactoring of emoji tags config to use groups
  ...
2019-04-09 21:33:18 +03:00
Henry Jameson
325c4b0a9f Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop:
  Return 403 on oauth token exchange for a deactivated user
2019-04-07 12:20:20 +03:00
Henry Jameson
4069f6430d update mrf 2019-04-07 12:13:49 +03:00
Henry Jameson
22bb706770 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (87 commits)
  Pin recon dependency to 2.4.0
  Redirect to the referer url after mastofe authorization
  Mock :crypt.crypt/2 because otherwise the test fails on Mac OS
  Revert "Merge branch 'test-coverage' into 'develop'"
  Use --cover option when running CI tests
  We actually want the user id not nickname in the test...
  Also remove Repo functions in the tests
  Redundant Repo.get_by usage was recently removed from the codebase
  Document the admin API endpoints for controlling follow/unfollow
  Add user following / unfollowing to the admin api.
  Refactor html caching functions to have a key instead of a module, use more correct terminology and fix summaries in mastoapi
  Add ability to ship logs to a Slack channel
  Code readability tweak
  Clean merge crumbs
  Serve metrics at `/api/pleroma/app_metrics`
  Document Prometheus
  [#1] fix telemetry
  Set up telemetry and prometheus
  Add recon
  mastodon_api_controller.ex: Add pleroma-tan to initial_state
  ...
2019-04-06 22:24:38 +03:00
Henry Jameson
5f41c54d8c Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop:
  Fix muting reblogs tests
  Fix missing announces in MastoAPI home timeline
  Add more user filters + move search to its own module
  Add vapid_key to the `POST /api/v1/apps` response
  Add GET /api/v1/apps/verify_credentials
2019-03-27 21:36:59 +02:00
Henry Jameson
3af3e07312 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (55 commits)
  AP UserView: Refactor banner / avatar display code, add test.
  Test for MastoAPI /api/v1/instance response structure (formatting fix).
  Test for MastoAPI /api/v1/instance response structure.
  Credo is upset about me not remembering the alphabet
  Fix formatting
  Remove ActivityRepresenter
  Mastodon 2.7.2 instance attributes (registrations, languages).
  Increment replies_count on replies (MastoAPI)
  Comments split.
  Mastodon-based auth error messages. Defaulted User#auth_active?/1 to `true`.
  Try sending an empty map
  Attempt to fix incorrect federation of default instance avatars
  Add an id index to notifications
  fix up missing announcements with preloads
  Serve non-public activities in /api/v1/favourites
  add overriding truncated_namespace condition for truncating paths for digital ocean
  mrf/keyword_policy.ex: Fix when summary == nil, do not whitelist content == nil
  tests: fix up activity collision test
  activity: use left join instead of inner join when fetching activities that may or may not have a child object
  user: use preloads when deleting accounts
  ...
2019-03-26 21:48:12 +02:00
Henry Jameson
c7ccd43500 shitfuck 2019-03-21 20:39:46 +02:00
Henry Jameson
580787d360 piece of shit 2019-03-21 20:35:52 +02:00
Henry Jameson
9bb34a12eb Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (87 commits)
  Add a gopher url port config option
  modify the migrations to use naive_datetime_usec
  Fix filter migration
  Fix migration timestamp type
  Ecto 3.0.5 migration
  Update frontend
  Format
  Use ILIKE to search users
  transmogrifier: upgrade: when upgrading OStatus users to AP, ensure we always use the fake collection
  user: properly cope with actors which do not declare a followers collection
  transmogrifier: when determining followers collection URI, we may need to fetch the actor
  test: add test for list sanitization
  tests: add test for as:Public issues
  activitypub: transmogrifier: do not allow missing lists to be interpreted as nil
  activitypub: transmogrifier: ensure as:Public activities are delivered to followers
  fix UploadTest to use new image_tmp.jpg
  used imageOptim to reduce size of image files
  Document additional pleroma changes to /api/v1/accounts/:id
  Check if the user has indeed not been federated with
  Added support for exclude_types, limit, and min_id in Mastodon notifications.
  ...
2019-03-21 20:26:26 +02:00
Henry Jameson
a9eb20e2db Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (24 commits)
  MastoAPI followers/following endpoints
  Switch the CI to Elixir 1.8.1
  Linting.
  WebPush: Add activity id to the push messages.
  MastoAPI Accounts: Add fetching by nickname.
  Update Differences-in-MastodonAPI-Responses.md
  Remove chromium input hilight that clashes with our own
  Style again the login page to fit pleroma more
  MastoAPI StatusView: Add locality indicator.
  Broadcast deleted activity id on deletion to conform to MastoAPI streamig spec
  Change order of source code to align with platforms
  Update homepages and provide source code links for Roma apps in Clients.md
  Rename Mastalab -> Fedilab in Clients.md
  http: connection: unify adapter configuration and defaults
  http: connection: relax the timeouts a little
  http: rework connection timeouts to match hackney docs, enforce 1 second max TCP connection timeout
  http: actually pass the options list to the Connection factory
  http: connection: merge hackney option lists instead of concatenating them
  http: safely catch erlang exits and elixir errors from hackney (ref #672)
  Allow an admin to delete a user status
  ...
2019-03-12 21:50:45 +02:00
Henry Jameson
66185ad957 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (62 commits)
  update pleroma frontend
  tests: add regression test
  MRF: anti followbot: gracefully handle accounts without a display name
  Adjust delete activity audience to match the deleted object
  Revert existing object check
  Preserve parameters in link headers (Mastodon API)
  [#647] tests for web push
  Keep heading short
  Add default config for masto_fe
  Add handling of objects not in database
  Add tests for reserved char escaping in upload
  Properly escape reserved URI charachters in upload urls
  Web.RelMe: Fix having other values in rel attr
  Plugs.HTTPSecurityPlug: Add static_url to CSP's connect-src
  Include admins in nodeinfo
  Typo
  rich media: helpers: rework validate_page_url()
  local -> only_local
  Format & update docs
  helpers: use AutoLinker to validate URIs as well as the other tests
  ...
2019-03-07 19:54:48 +02:00
Henry Jameson
f95b354c3d configs update 2019-03-03 21:33:48 +02:00
Henry Jameson
af8a7d8fd8 limit 2019-03-02 20:25:21 +02:00
Henry Jameson
ae07bb4779 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (208 commits)
  Web.OAuth.OAuthControllerTest: Add test against token formatting
  Web.OAuth.OAuthController: Fix scopes Enum.join for OAuth response
  activitypub: fix date header format
  Added migration for setting default tags in existing users records
  config: fix chat endpoint path
  mastodon websocket: return errors using ok, not stop
  mastodon websocket: bring back infinity timeout
  mastodon websocket: use pattern match to get query data, robustly handle errors
  config: update config for cowboy 2 endpoints
  mastodon api: websocket: update code for cowboy 2.x
  mix: update dependencies for cowboy 2.0
  Renamed *DatabaseAuthenticator to *Authenticator.
  Added `auth_template/0` to DatabaseAuthenticator.
  Made auth customization be runtime-configurable.
  Added deactivated to the user view
  Remove parts of the old activity view.
  Add user muted status info to twitterapi.
  Add user muted status info to MastodonAPI.
  Add `with_muted` param.
  Follower requests: Utilize object index.
  ...
2019-03-02 20:20:45 +02:00
Henry Jameson
f1bb6b6bc4 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (280 commits)
  Mark streaming feature for Apps in README.md
  Update README.md
  hide_followings was renamed to hide_followers in the FE, but never synced up in the BE
  tests: add a rich media card that contains all relevant fields
  test: add some regression tests for the rich media card rendering
  mastodon api: rich media: don't clobber %URI struct with a string
  adds a couple of explicit examples for ExSyslogger
  Fix if clause in activity_pub user_view
  rids the duplicate timestamp from default ExSyslogger config
  update frontend
  Allow to configure visibility for admin and moderator badges
  Add is_admin and is_moderator boolean fields to the user view
  rich media: parser: reject any data which cannot be explicitly encoded into JSON
  test: twitterapi: fix another possible test failure case
  test: twitterapi: fix the test breakage for real
  mastodon api: fix rendering of cards without image URLs (closes #597)
  Fix SQL
  ARGLE GARBLE
  html: don't attempt to parse nil content
  activitypub: transmogrifier: fix bare tags
  ...
2019-02-08 10:08:36 +02:00
Henry Jameson
37aa9a63b0 allow only plaintext 2019-01-21 15:52:44 +03:00
Henry Jameson
f314d1b9d5 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (194 commits)
  Mix.Tasks.Pleroma.Instance: Generate signing_salt
  Send delete event over Mastodon streaming api
  Add a test to ensure #39 is fixed.
  update frontend
  Set custom similarity limit.
  Make use of the indices.
  test: add regression test for to/cc clobbering
  [#477] User trigram index adjustment.
  [#477] User: FTS and trigram search results mixing (to handle misspelled requests).
  [#491] Made full nicknames be preserved in user links text only in Bio.
  activitypub: add a match clause for objects, not just activities
  activitypub: transmogrifier: do not clobber the addressing on relayed announcements
  activitypub: allow is_public?() to work on any type of map representing an AS2 object
  activitypub: relay: chase selective public announce changes
  activitypub: announce: add new public parameter
  Add comments and change default path of the Mix binary.
  Fix bad link in likes collection
  [#502] Fixed `user_count` in `/api/v1/instance` to include only active local users.
  formatting
  Default to disabled in the code in case the setting is absent from config.exs
  ...
2019-01-21 14:35:25 +03:00
Henry Jameson
6cf02b501a Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (53 commits)
  tests: add legal boilerplate
  mix tasks: add legal boilerplate
  add license boilerplate to pleroma core
  tests: twitter api: add test proving that peertube videos are correctly handled
  twitter api: add "Video" to supported activity types list
  tests: twitter api: activity view test: enable tesla mock
  twitter api: activity representer: remove peertube hack
  tests: mastodon api: add test verifying that peertube videos are correctly rendered
  mastodon api: status view: remove obsolete peertube hack
  transmogrifier: significantly rework handling of peertube videos, add test
  transmogrifier: When it’s a Video move "url" to "attachment"
  Implement kaniini's tweaks
  Renamed the things
  Add documentation
  Fix formatting
  Implement large thread filter
  [#114] Fixed test.
  [#114] Allowed unconfirmed users to authenticate if :account_activation_required is disabled prior to confirmation. Ensured that no confirmation emails are sent if :account_activation_required is not true. Adjusted tests.
  [#114] Added :user_id component to email confirmation path to improve the security. Added tests for `confirm_email` action.
  [#114] Removed flash messages rendering on redirects.
  ...
2018-12-26 10:25:38 +03:00
Henry Jameson
4349a83b9d Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (295 commits)
  update frontend
  Fix uploads test.
  fix text field
  don't re-use build
  Fix tagging problems for existing instances.
  Alias Kocaptcha in the test
  Use :ets.match_delete to delete old captchas
  Switch to phoenixframework/phoenix as the needed change is merged.
  Integration tests for mastodon websocket
  Cowboy handler for Mastodon WebSocket
  Support both OAuth token record and token string in UserView
  minutes->seconds_retained in config.md
  Clean captchas up periodically, not schedule it after theyre created
  Fix captcha tests
  Change minutes_retained config to seconds_retained
  Make the hosted kocaptcha the default value
  Add a configurable auto-cleanup for captchas
  More put_view.
  Use bindings dbuser and dbname in sample_psql.eex
  Upgrade to Phoenix 1.4
  ...
2018-12-18 07:32:00 +03:00
Henry Jameson
f077d41b12 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (92 commits)
  Web.MastodonApi.MastodonSocketTest: Add test for unauthenticated websocket
  Web.Streamer: Get unauthenticated statuses representation
  Web.MastodonAPI.MastodonSocket: Put access_token at function-level
  Web.MastodonAPI.MastodonSocket: Add unauthentified websocket endpoints
  Improved version string
  mediaproxy: fix empty url & add some tests
  RetryQueue: tiny refractor, add tests
  Various runtime configuration fixes
  update pleroma frontend
  Federator: add retry queue.
  activitypub: object view: avoid leaking private details
  ostatus controller: respond with AS2 objects instead of activities to notice URIs
  tests: federator: fix formatting
  activitypub: transmogrifier: make deletes secure
  Web.AdminAPI.AdminAPIControllerTest: New Test
  Web.AdminAPI.AdminAPIController: Fixes bugs found with ExUnit
  test/plugs/user_is_admin_plug_test: New test
  lib/mix/tasks/relay*: Use a with block
  Change Relay from `status` to `{status, message}`
  Web.Router: Change right to permission group (except for function names)
  ...
2018-11-26 17:52:07 +03:00
Henry Jameson
08ab82cf0b fix 2018-11-12 16:26:43 +03:00
Henry Jameson
bc0f261f72 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (207 commits)
  Update README.md
  Mastodon API: Fix list streaming
  nginx example config: remove CORS headers, now managed by CORSPlug.
  config: properly configure CORSPlug.
  oauth: fix token decode regression
  tests: add test for internal data stripping
  activitypub: transmogrifier: sanitize internal representation details from outgoing objects
  lib/mix/tasks: s/@doc/@moduledoc/
  lib/mix/tasks/unsubscribe_user.ex: Fix syntax from bad line copy
  lib/mix/tasks: Add remaining documentation for mix tasks
  config/config.md: Add lines inspired/copied from CONFIGURATION.md
  README.md: Add note about config/config.md
  README.md: Put the systemd’s .service note to the relevant section
  README.md: Add note for OpenRC
  config/config.md: scope_options_enabled also addresses subject
  config/config.md: Fill all the blanks
  config/config.md: Complete it [WIP]
  config/config.md: Create
  Document the mix tasks in ex_doc instead
  Document mix tasks
  ...
2018-11-12 16:17:34 +03:00
Henry Jameson
d5e4b906c9 Merge remote-tracking branch 'origin/develop' into shigusegubu
* origin/develop: (129 commits)
  Uploaders.S3: Replace unsafe characters in object key
  update pleroma frontend
  test: add smoketests for the scrubbing policies
  html: twittertext: add missing catchall scrub function
  twitter api: add no_rich_text option to userview for account prefs
  test: add tests for new User.html_filter_policy()
  mastodon api: formatting
  twitter api: add support for disabling rich text
  mastodon api: add support for user-supplied html policy
  twitter api: add support for user-specified html policy
  user: add User.html_filter_policy()
  html: default to using normal scrub policy if provided scrub policy is nil
  mix: remove fix_ap_users task, now obsolete
  test: add test proving that users are refreshed when stale
  user: implement dynamic refresh of profiles (gets rid of need for fix_ap_users task)
  Update mastodon frontend
  [Pleroma.Web.MastodonAPI.MastodonAPIController]: Bump mastodon_api_level to 2.5.0
  [Pleroma.Web.MastodonAPI.MastodonAPIController]: Remove unused variables
  [Pleroma.Web.Router]: Fake /api/v1/endorsements
  [Pleroma.Web.MastodonAPI.AccountView]: relationship.json: fake endorsed value (false)
  ...
2018-09-25 16:18:28 +03:00
Henry Jameson
5720cf286c changes 2018-09-25 15:56:43 +03:00
SGSGB
5379db3194 Merge remote-tracking branch 'origin/develop' into shigusegubu 2018-08-29 21:56:22 +02:00
SGSGB
dae06c0944 Merge remote-tracking branch 'origin/develop' into shigusegubu 2018-08-29 12:08:34 +02:00
SGSGB
00296406fa Merge remote-tracking branch 'origin/develop' into shigusegubu 2018-08-13 08:07:20 +02:00
SGSGB
2c15ffb421 Merge remote-tracking branch 'origin/develop' into shigusegubu 2018-08-04 18:24:38 +02:00
SGSGB
21e6c1dfcb customs 2018-08-04 18:23:11 +02:00
SGSGB
d5f36acd13 emoji movement 2018-07-06 18:59:07 +02:00
Pleroma
fe8ec1b6f9 shigusegubu customs 2018-07-06 18:59:00 +02:00
1113 changed files with 4965 additions and 33489 deletions

View file

@ -1,25 +0,0 @@
name: 'Bug report'
about: 'Report a bug in Pleroma'
body:
- type: markdown
attributes:
value: |
### Precheck
* For support use https://git.pleroma.social/pleroma/pleroma-support or [community channels](https://git.pleroma.social/pleroma/pleroma#community-channels).
* Please do a quick search to ensure no similar bug has been reported before. If the bug has not been addressed after 2 weeks, it's fine to bump it.
* Try to ensure that the bug is actually related to the Pleroma backend. For example, if a bug happens in Pleroma-FE but not in Mastodon-FE or mobile clients, it's likely that the bug should be filed in [Pleroma-FE](https://git.pleroma.social/pleroma/pleroma-fe/issues/new) repository.
- type: textarea
id: environment
attributes:
label: Environment
value: |
* Installation type (OTP or From Source):
* Pleroma version (could be found in the "Version" tab of settings in Pleroma-FE):
* Elixir version (`elixir -v` for from source installations, N/A for OTP):
* Operating system:
* PostgreSQL version (`psql -V`):
- type: textarea
id: bug-description
attributes:
label: Bug description

View file

@ -1,13 +0,0 @@
### Checklist
- [ ] Adding a changelog: In the `changelog.d` directory, create a file named `<code>.<type>`.
<!--
`<code>` can be anything, but we recommend using a more or less unique identifier to avoid collisions, such as the branch name.
`<type>` can be `add`, `change`, `remove`, `fix`, `security` or `skip`. `skip` is only used if there is no user-visible change in the PR (for example, only editing comments in the code). Otherwise, choose a type that corresponds to your change.
In the file, write the changelog entry. For example, if a PR adds group functionality, we can create a file named `group.add` and write `Add group functionality` in it.
If one changelog entry is not enough, you may add more. But that might mean you can split it into two PRs. Only use more than one changelog entry if you really need to (for example, when one change in the code fix two different bugs, or when refactoring).
-->

3
.gitignore vendored
View file

@ -56,9 +56,6 @@ pleroma.iml
# asdf # asdf
.tool-versions .tool-versions
# mise
mise.toml
# Editor temp files # Editor temp files
*~ *~
*# *#

View file

@ -1,20 +0,0 @@
when:
- event: pull_request
evaluate: 'CI_COMMIT_SOURCE_BRANCH != "weblate"'
labels:
platform: linux/amd64
variables:
script_file_entrypoint: &script_file_entrypoint
- /bin/sh
- -c
- 'printf "%s" "$CI_SCRIPT" | base64 -d > /tmp/ci-script.sh && /bin/sh -xe /tmp/ci-script.sh'
steps:
check-changelog:
image: docker.io/alpine:3.23
entrypoint: *script_file_entrypoint
commands:
- apk add --no-cache git
- sh ./tools/check-changelog

View file

@ -1,60 +0,0 @@
when:
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
path: [ "**/*.ex", "**/*.eex", "**/*.exs", "mix.lock", ".woodpecker/**", "Dockerfile" ]
- event: tag
- event: manual
branch: ${CI_REPO_DEFAULT_BRANCH}
- event: manual
branch: stable
depends_on:
- docker
skip_clone: true
labels:
platform: linux/amd64
steps:
docker-develop-combine:
image: &docker_image git.pleroma.social/phnt/wpc-docker-tagger:0.9.1
when:
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
- event: manual
branch: ${CI_REPO_DEFAULT_BRANCH}
settings: &docker_settings
registry: "git.pleroma.social"
image: "pleroma/pleroma"
architectures: [amd64, arm64, armv7]
tags:
- latest
- develop
- "${CI_COMMIT_SHA:0:8}"
username:
from_secret: pleroma-ci-user
password:
from_secret: pleroma-ci-password
docker-stable-combine:
image: *docker_image
when:
- evaluate: 'CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable" && CI_COMMIT_TAG == ""'
settings:
<<: *docker_settings
tags: &stable_docker_tags
- latest
- stable
- "${CI_COMMIT_SHA:0:8}"
docker-stable-tag-combine:
image: *docker_image
when:
- event: tag
- evaluate: 'CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable" && CI_COMMIT_TAG != ""'
settings:
<<: *docker_settings
tags:
- <<: *stable_docker_tags
- "${CI_COMMIT_TAG}"

View file

@ -1,150 +0,0 @@
when:
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
path: [ "**/*.ex", "**/*.eex", "**/*.exs", "mix.lock", ".woodpecker/**", "Dockerfile" ]
- event: tag
- event: manual
branch: ${CI_REPO_DEFAULT_BRANCH}
- event: manual
branch: stable
matrix:
platform:
- linux/amd64
- linux/arm64
- linux/arm
# This is needed for the when clauses below.
labels:
platform: ${platform}
memory: 'high'
variables:
docker_variables: &docker_variables
repo: pleroma/pleroma
registry: git.pleroma.social
username:
from_secret: pleroma-ci-user
password:
from_secret: pleroma-ci-password
armv7_docker_variables: &armv7_docker_variables
<<: *docker_variables
build_args:
- ELIXIR_IMG=docker.io/arm32v7/elixir
- ELIXIR_TAG=1.17.3-otp-27-alpine
- ALPINE_IMG=docker.io/arm32v7/alpine
- ALPINE_VER=3.20
extra_opts: --custom-platform=linux/arm/v7
kaniko_image: &kaniko_image docker.io/woodpeckerci/plugin-kaniko:2.3.2
steps:
docker-develop-amd64:
image: *kaniko_image
when:
- evaluate: 'platform == "linux/amd64" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
settings:
<<: *docker_variables
tags:
- latest-amd64
- develop-amd64
- ${CI_COMMIT_SHA:0:8}-amd64
docker-develop-arm64:
image: *kaniko_image
when:
- evaluate: 'platform == "linux/arm64" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
settings:
<<: *docker_variables
tags:
- latest-arm64
- develop-arm64
- ${CI_COMMIT_SHA:0:8}-arm64
docker-develop-armv7:
image: *kaniko_image
when:
- evaluate: 'platform == "linux/arm" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
settings:
<<: *armv7_docker_variables
tags:
- latest-armv7
- develop-armv7
- ${CI_COMMIT_SHA:0:8}-armv7
docker-stable-amd64:
image: *kaniko_image
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable" && CI_COMMIT_TAG == ""'
settings:
<<: *docker_variables
tags: &amd64_tags
- latest-amd64
- stable-amd64
- ${CI_COMMIT_SHA:0:8}-amd64
# FE workflow runs only on linux/amd64
docker-stable-e2e-amd64:
image: *kaniko_image
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "tag"'
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable"'
settings:
<<: *docker_variables
dockerfile: Dockerfile-e2e
tags:
- stable-e2e
docker-stable-tag-amd64:
image: *kaniko_image
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "tag"'
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable" && CI_COMMIT_TAG != ""'
settings:
<<: *docker_variables
tags:
- <<: *amd64_tags
- ${CI_COMMIT_TAG}-amd64
docker-stable-arm64:
image: *kaniko_image
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable" && CI_COMMIT_TAG == ""'
settings:
<<: *docker_variables
tags: &arm64_tags
- latest-arm64
- stable-arm64
- ${CI_COMMIT_SHA:0:8}-arm64
docker-stable-tag-arm64:
image: *kaniko_image
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "tag"'
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable" && CI_COMMIT_TAG != ""'
settings:
<<: *docker_variables
tags:
- <<: *arm64_tags
- ${CI_COMMIT_TAG}-arm64
docker-stable-armv7:
image: *kaniko_image
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable" && CI_COMMIT_TAG == ""'
settings:
<<: *armv7_docker_variables
tags: &armv7_tags
- latest-armv7
- stable-armv7
- ${CI_COMMIT_SHA:0:8}-armv7
docker-stable-tag-armv7:
image: *kaniko_image
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "tag"'
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable" && CI_COMMIT_TAG != ""'
settings:
<<: *armv7_docker_variables
tags:
- <<: *armv7_tags
- ${CI_COMMIT_TAG}-armv7

View file

@ -1,45 +0,0 @@
when:
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
path: [ "docs/**" ]
- event: tag
- event: manual
evaluate: 'CI_COMMIT_BRANCH == "stable" || CI_COMMIT_BRANCH == CI_REPO_DEFAULT_BRANCH'
labels:
platform: linux/amd64
skip_clone: true
variables:
trigger_settings: &trigger_settings
deploy: 'docs'
last-successful: true
token:
from_secret: pleroma-ci-woodpecker-token
repositories:
- pleroma/docs@master
docker_image: &docker_image docker.io/woodpeckerci/plugin-trigger:1.1.1
steps:
trigger-deploy-stable:
when:
- event: tag
- event: manual
branch: stable
image: *docker_image
settings:
<<: *trigger_settings
params:
- BRANCH=stable
trigger-deploy-develop:
when:
- event: push
- event: manual
branch: ${CI_REPO_DEFAULT_BRANCH}
image: *docker_image
settings:
<<: *trigger_settings
params:
- BRANCH=develop

View file

@ -1,78 +0,0 @@
when:
- event: pull_request
path: [ "**/*.ex", "**/*.eex", "**/*.exs", "mix.lock", ".woodpecker/**" ]
evaluate: 'CI_COMMIT_SOURCE_BRANCH != "weblate"'
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
path: [ "**/*.ex", "**/*.eex", "**/*.exs", "mix.lock", ".woodpecker/**" ]
labels:
platform: linux/amd64
variables:
script_file_entrypoint: &script_file_entrypoint
- /bin/sh
- -c
- 'printf "%s" "$CI_SCRIPT" | base64 -d > /tmp/ci-script.sh && /bin/sh -xe /tmp/ci-script.sh'
steps:
mix-format:
image: &elixir-image
docker.io/elixir:1.17-otp-27-alpine
entrypoint: *script_file_entrypoint
failure: ignore
commands:
- |
if ! mix format --check-formatted; then
touch fail.stamp
exit 1
fi
credo:
image: *elixir-image
entrypoint: *script_file_entrypoint
failure: ignore
environment:
MIX_ENV: test
commands:
- apk add --no-cache build-base cmake exiftool ffmpeg file-dev git openssl
- adduser -D -h /home/testuser testuser
- mkdir -p /home/testuser/.mix /home/testuser/.hex
- chown -R testuser:testuser . /home/testuser
- su testuser -c "HOME=/home/testuser mix local.hex --force"
- su testuser -c "HOME=/home/testuser mix local.rebar --force"
- su testuser -c "HOME=/home/testuser mix deps.get"
- |
if ! su testuser -c "HOME=/home/testuser mix analyze"; then
touch fail.stamp
exit 1
fi
# cycles:
# image: *elixir-image
# failure: ignore
# commands:
# - apk add --no-cache build-base cmake exiftool ffmpeg file-dev git openssl
# - adduser -D -h /home/testuser testuser
# - mkdir -p /home/testuser/.mix /home/testuser/.hex
# - chown -R testuser:testuser . /home/testuser
# - su testuser -c "HOME=/home/testuser mix local.hex --force"
# - su testuser -c "HOME=/home/testuser mix local.rebar --force"
# - su testuser -c "HOME=/home/testuser mix compile"
# - |
# if ! su testuser -c "HOME=/home/testuser mix xref graph --format cycles --label compile | awk '{print $0} END{exit ($0 != \"No cycles found\")}'"; then
# touch fail.stamp
# exit 1
# fi
ensure-status:
image: *elixir-image
entrypoint: *script_file_entrypoint
commands: |
if test -f fail.stamp; then
echo "One or more previous steps fails. Failing workflow..."
exit 1
else
echo "All steps passed"
exit 0
fi

View file

@ -1,292 +0,0 @@
when:
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
path: [ "**/*.ex", "**/*.eex", "**/*.exs", "mix.lock", ".woodpecker/**" ]
- event: tag
- event: manual
branch: ${CI_REPO_DEFAULT_BRANCH}
- event: manual
branch: stable
matrix:
platform:
- linux/amd64
- linux/arm
- linux/arm64
# This is needed for the when clauses below.
# When the platform clause is fixed, this might not be needed anymore
labels:
platform: ${platform}
variables:
script_file_entrypoint: &script_file_entrypoint
- /bin/sh
- -c
- 'printf "%s" "$CI_SCRIPT" | base64 -d > /tmp/ci-script.sh && /bin/sh -xe /tmp/ci-script.sh'
build_cmds: &build_cmds
- apk add git build-base cmake file-dev openssl vips-dev zip
- echo "import Config" > config/prod.secret.exs
- mix local.hex --force
- mix local.rebar --force
- mix deps.get --only prod
- mkdir release
- export PLEROMA_BUILD_BRANCH=${CI_COMMIT_BRANCH}
- mix release --path release
build_image_amd64: &build_image_amd64 docker.io/hexpm/elixir:1.17.3-erlang-27.3.4.17-alpine-3.22.5
build_image_arm: &build_image_arm docker.io/arm32v7/elixir:1.17.3-alpine
build_image_arm64: &build_image_arm64 docker.io/hexpm/elixir:1.17.3-erlang-27.3.4.17-alpine-3.22.5
artifacts_uploader_image: &artifacts_uploader_image docker.io/woodpeckercommunity/plugin-gitea-package:0.5.1
artifacts_uploader_settings: &artifacts_uploader_settings
user:
from_secret: pleroma-ci-user
password:
from_secret: pleroma-ci-password
owner: 'pleroma'
env: &env
MIX_ENV: prod
VIX_COMPILATION_MODE: PLATFORM_PROVIDED_LIBVIPS
steps:
otp-develop-amd64-musl:
image: *build_image_amd64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/amd64" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
environment: *env
commands: &amd64_build
- <<: *build_cmds
- zip -9rq ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-amd64-musl.zip release
otp-stable-amd64-musl:
image: *build_image_amd64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable"'
environment: *env
commands: *amd64_build
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
otp-stable-tag-amd64-musl:
image: *build_image_amd64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "tag"'
environment: *env
commands:
- <<: *build_cmds
- zip -9rq stable-${CI_COMMIT_SHA:0:8}-amd64-musl.zip release
otp-develop-arm-musl:
image: *build_image_arm
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
environment: *env
commands: &arm_build
- <<: *build_cmds
- zip -9rq ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm-musl.zip release
otp-stable-arm-musl:
image: *build_image_arm
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable"'
environment: *env
commands: *arm_build
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
otp-stable-tag-arm-musl:
image: *build_image_arm
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "tag"'
environment: *env
commands:
- <<: *build_cmds
- zip -9rq stable-${CI_COMMIT_SHA:0:8}-arm-musl.zip release
otp-develop-arm64-musl:
image: *build_image_arm64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm64" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
environment: *env
commands: &arm64_build
- <<: *build_cmds
- zip -9rq ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm64-musl.zip release
otp-stable-arm64-musl:
image: *build_image_arm64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable"'
environment: *env
commands: *arm64_build
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
otp-stable-tag-arm64-musl:
image: *build_image_arm64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "tag"'
environment: *env
commands:
- <<: *build_cmds
- zip -9rq stable-${CI_COMMIT_SHA:0:8}-arm64-musl.zip release
upload-artifacts-amd64-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-amd64-musl
package_version: ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-amd64-musl
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-amd64-musl.zip
file_name: pleroma-${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-amd64-musl.zip
update: 'true'
upload-latest-amd64-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-amd64-musl
package_version: latest
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-amd64-musl.zip
file_name: pleroma.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-artifacts-tag-amd64-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-amd64-musl
package_version: stable-${CI_COMMIT_SHA:0:8}-amd64-musl
file_source: ./stable-${CI_COMMIT_SHA:0:8}-amd64-musl.zip
file_name: pleroma-stable-${CI_COMMIT_SHA:0:8}-amd64-musl.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-latest-tag-amd64-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-amd64-musl
package_version: latest
file_source: ./stable-${CI_COMMIT_SHA:0:8}-amd64-musl.zip
file_name: pleroma.zip
update: 'true'
upload-artifacts-arm-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-arm-musl
package_version: ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm-musl
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm-musl.zip
file_name: pleroma-${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm-musl.zip
update: 'true'
upload-latest-arm-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-arm-musl
package_version: latest
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm-musl.zip
file_name: pleroma.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-artifacts-tag-arm-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-arm-musl
package_version: stable-${CI_COMMIT_SHA:0:8}-arm-musl
file_source: ./stable-${CI_COMMIT_SHA:0:8}-arm-musl.zip
file_name: pleroma-stable-${CI_COMMIT_SHA:0:8}-arm-musl.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-latest-tag-arm-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-arm-musl
package_version: latest
file_source: ./stable-${CI_COMMIT_SHA:0:8}-arm-musl.zip
file_name: pleroma.zip
update: 'true'
upload-artifacts-arm64-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-arm64-musl
package_version: ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm64-musl
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm64-musl.zip
file_name: pleroma-${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm64-musl.zip
update: 'true'
upload-latest-arm64-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-arm64-musl
package_version: latest
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm64-musl.zip
file_name: pleroma.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-artifacts-tag-arm64-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-arm64-musl
package_version: stable-${CI_COMMIT_SHA:0:8}-arm64-musl
file_source: ./stable-${CI_COMMIT_SHA:0:8}-arm64-musl.zip
file_name: pleroma-stable-${CI_COMMIT_SHA:0:8}-arm64-musl.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-latest-tag-arm64-musl:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-arm64-musl
package_version: latest
file_source: ./stable-${CI_COMMIT_SHA:0:8}-arm64-musl.zip
file_name: pleroma.zip
update: 'true'

View file

@ -1,293 +0,0 @@
when:
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
path: [ "**/*.ex", "**/*.eex", "**/*.exs", "mix.lock", ".woodpecker/**" ]
- event: tag
- event: manual
branch: ${CI_REPO_DEFAULT_BRANCH}
- event: manual
branch: stable
matrix:
platform:
- linux/amd64
- linux/arm
- linux/arm64
# This is needed for the when clauses below.
# When the platform clause is fixed, this might not be needed anymore
labels:
platform: ${platform}
variables:
script_file_entrypoint: &script_file_entrypoint
- /bin/sh
- -c
- 'printf "%s" "$CI_SCRIPT" | base64 -d > /tmp/ci-script.sh && /bin/sh -xe /tmp/ci-script.sh'
build_cmds: &build_cmds
- apt-get update && apt-get install -y cmake libmagic-dev libvips-dev erlang-dev git build-essential zip
- echo "import Config" > config/prod.secret.exs
- mix local.hex --force
- mix local.rebar --force
- mix deps.get --only prod
- mkdir release
- export PLEROMA_BUILD_BRANCH=${CI_COMMIT_BRANCH}
- mix release --path release
build_image_amd64: &build_image_amd64 docker.io/hexpm/elixir:1.17.3-erlang-27.3.4.17-ubuntu-noble-20260810
build_image_arm: &build_image_arm docker.io/arm32v7/elixir:1.17.3
build_image_arm64: &build_image_arm64 docker.io/hexpm/elixir:1.17.3-erlang-27.3.4.17-ubuntu-noble-20260810
artifacts_uploader_image: &artifacts_uploader_image docker.io/woodpeckercommunity/plugin-gitea-package:0.5.1
artifacts_uploader_settings: &artifacts_uploader_settings
user:
from_secret: pleroma-ci-user
password:
from_secret: pleroma-ci-password
owner: 'pleroma'
env: &env
MIX_ENV: prod
VIX_COMPILATION_MODE: PLATFORM_PROVIDED_LIBVIPS
DEBIAN_FRONTEND: noninteractive
steps:
otp-develop-amd64:
image: *build_image_amd64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/amd64" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
environment: *env
commands: &amd64_build
- <<: *build_cmds
- zip -9rq ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-amd64.zip release
otp-stable-amd64:
image: *build_image_amd64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable"'
environment: *env
commands: *amd64_build
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
otp-stable-tag-amd64:
image: *build_image_amd64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "tag"'
environment: *env
commands:
- <<: *build_cmds
- zip -9rq stable-${CI_COMMIT_SHA:0:8}-amd64.zip release
otp-develop-arm:
image: *build_image_arm
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
environment: *env
commands: &arm_build
- <<: *build_cmds
- zip -9rq ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm.zip release
otp-stable-arm:
image: *build_image_arm
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable"'
environment: *env
commands: *arm_build
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
otp-stable-tag-arm:
image: *build_image_arm
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "tag"'
environment: *env
commands:
- <<: *build_cmds
- zip -9rq stable-${CI_COMMIT_SHA:0:8}-arm.zip release
otp-develop-arm64:
image: *build_image_arm64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm64" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
environment: *env
commands: &arm64_build
- <<: *build_cmds
- zip -9rq ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm64.zip release
otp-stable-arm64:
image: *build_image_arm64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "manual" && CI_COMMIT_BRANCH == "stable"'
environment: *env
commands: *arm64_build
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
otp-stable-tag-arm64:
image: *build_image_arm64
entrypoint: *script_file_entrypoint
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "tag"'
environment: *env
commands:
- <<: *build_cmds
- zip -9rq stable-${CI_COMMIT_SHA:0:8}-arm64.zip release
upload-artifacts-amd64:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-amd64
package_version: ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-amd64
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-amd64.zip
file_name: pleroma-${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-amd64.zip
update: 'true'
upload-latest-amd64:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-amd64
package_version: latest
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-amd64.zip
file_name: pleroma.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-artifacts-tag-amd64:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-amd64
package_version: stable-${CI_COMMIT_SHA:0:8}-amd64
file_source: ./stable-${CI_COMMIT_SHA:0:8}-amd64.zip
file_name: pleroma-stable-${CI_COMMIT_SHA:0:8}-amd64.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-latest-tag-amd64:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/amd64" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-amd64
package_version: latest
file_source: ./stable-${CI_COMMIT_SHA:0:8}-amd64.zip
file_name: pleroma.zip
update: 'true'
upload-artifacts-arm:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-arm
package_version: ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm.zip
file_name: pleroma-${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm.zip
update: 'true'
upload-latest-arm:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-arm
package_version: latest
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm.zip
file_name: pleroma.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-artifacts-tag-arm:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-arm
package_version: stable-${CI_COMMIT_SHA:0:8}-arm
file_source: ./stable-${CI_COMMIT_SHA:0:8}-arm.zip
file_name: pleroma-stable-${CI_COMMIT_SHA:0:8}-arm.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-latest-tag-arm:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-arm
package_version: latest
file_source: ./stable-${CI_COMMIT_SHA:0:8}-arm.zip
file_name: pleroma.zip
update: 'true'
upload-artifacts-arm64:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-arm64
package_version: ${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm64
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm64.zip
file_name: pleroma-${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm64.zip
update: 'true'
upload-latest-arm64:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "push" && CI_COMMIT_BRANCH == "${CI_REPO_DEFAULT_BRANCH}"'
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "manual"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-${CI_COMMIT_BRANCH}-arm64
package_version: latest
file_source: ./${CI_COMMIT_BRANCH}-${CI_COMMIT_SHA:0:8}-arm64.zip
file_name: pleroma.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-artifacts-tag-arm64:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-arm64
package_version: stable-${CI_COMMIT_SHA:0:8}-arm64
file_source: ./stable-${CI_COMMIT_SHA:0:8}-arm64.zip
file_name: pleroma-stable-${CI_COMMIT_SHA:0:8}-arm64.zip
update: 'true'
# Tag events don't have CI_COMMIT_BRANCH set, hardcode stable
upload-latest-tag-arm64:
image: *artifacts_uploader_image
when:
- evaluate: 'platform == "linux/arm64" && CI_PIPELINE_EVENT == "tag"'
settings:
<<: *artifacts_uploader_settings
package_name: pleroma-otp-stable-arm64
package_version: latest
file_source: ./stable-${CI_COMMIT_SHA:0:8}-arm64.zip
file_name: pleroma.zip
update: 'true'

View file

@ -1,66 +0,0 @@
when:
- event: pull_request
path:
- ".woodpecker/**"
- "lib/pleroma/search/**"
- "test/pleroma/search/**"
- "mix.exs"
- "mix.lock"
evaluate: 'CI_COMMIT_SOURCE_BRANCH != "weblate"'
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
path:
- ".woodpecker/**"
- "lib/pleroma/search/**"
- "test/pleroma/search/**"
- "mix.exs"
- "mix.lock"
depends_on:
- lint
labels:
platform: linux/amd64
variables:
script_file_entrypoint: &script_file_entrypoint
- /bin/sh
- -c
- 'printf "%s" "$CI_SCRIPT" | base64 -d > /tmp/ci-script.sh && /bin/sh -xe /tmp/ci-script.sh'
steps:
paradedb-integration:
image: docker.io/elixir:1.19-otp-28-alpine
entrypoint: *script_file_entrypoint
environment:
MIX_ENV: test
VIX_COMPILATION_MODE: PLATFORM_PROVIDED_LIBVIPS
DB_HOST: postgres
DB_PORT: 5432
PARADEDB_TEST_URL: postgres://postgres:postgres@paradedb:5432/paradedb
commands:
- apk add --no-cache build-base cmake exiftool ffmpeg vips-dev file-dev git openssl postgresql-client
- mix local.hex --force
- mix local.rebar --force
- mix deps.get
- timeout 60 sh -c 'until pg_isready -h postgres -U postgres -d pleroma_test; do sleep 1; done' || { echo "PostgreSQL did not become ready" >&2; exit 1; }
- timeout 60 sh -c 'until pg_isready -h paradedb -U postgres -d paradedb; do sleep 1; done' || { echo "ParadeDB did not become ready" >&2; exit 1; }
- mix ecto.create
- mix ecto.migrate
- mix test --include integration test/pleroma/search/parade_db_integration_test.exs
services:
postgres:
image: docker.io/postgres:13-alpine
failure: ignore
environment:
POSTGRES_DB: pleroma_test
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
paradedb:
image: docker.io/paradedb/paradedb:0.24.3-pg15@sha256:997d62f6c2605becb7c45878af3f8c8c698f355006b675b3ce212d4eb2d14f2e
failure: ignore
environment:
POSTGRES_DB: paradedb
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres

View file

@ -1,103 +0,0 @@
when:
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
path:
- ".woodpecker/spec-build.yaml"
- "mix.exs"
- "mix.lock"
- "lib/pleroma/web.ex"
- "lib/pleroma/web/**/*.ex"
- event: tag
- event: manual
evaluate: 'CI_COMMIT_BRANCH == "stable" || CI_COMMIT_BRANCH == CI_REPO_DEFAULT_BRANCH'
labels:
platform: linux/amd64
concurrency: 1
variables:
artifacts_uploader_image: &artifacts_uploader_image docker.io/woodpeckercommunity/plugin-gitea-package:0.5.1
artifacts_uploader_settings: &artifacts_uploader_settings
user:
from_secret: pleroma-ci-user
password:
from_secret: pleroma-ci-password
owner: 'pleroma'
package_name: api-docs-spec
file_source: ./spec.json
file_name: spec.json
update: 'true'
trigger_image: &trigger_image docker.io/woodpeckerci/plugin-trigger:1.1.1
trigger_settings: &trigger_settings
deploy: 'api-docs'
last-successful: true
token:
from_secret: pleroma-ci-woodpecker-token
repositories:
- pleroma/api-docs@master
steps:
build-spec:
image: docker.io/hexpm/elixir:1.17.3-erlang-27.3.4.17-alpine-3.22.5
environment:
MIX_ENV: prod
VIX_COMPILATION_MODE: PLATFORM_PROVIDED_LIBVIPS
commands:
- apk update --no-cache
- apk add git build-base cmake file-dev openssl vips-dev zip
- mix local.hex --force
- mix local.rebar --force
- mix deps.get --only prod
- mix pleroma.openapi_spec spec.json
- |
printf 'BRANCH=stable\nSPEC_VERSION=%s\n' "$${CI_COMMIT_SHA}" > trigger-deploy-stable.params
printf 'BRANCH=develop\nSPEC_VERSION=%s\n' "$${CI_COMMIT_SHA}" > trigger-deploy-develop.params
upload-spec:
image: *artifacts_uploader_image
settings:
<<: *artifacts_uploader_settings
package_version: ${CI_COMMIT_SHA}
upload-spec-stable:
when:
- event: tag
- event: manual
branch: stable
image: *artifacts_uploader_image
settings:
<<: *artifacts_uploader_settings
package_version: stable
upload-spec-develop:
when:
- event: push
- event: manual
branch: ${CI_REPO_DEFAULT_BRANCH}
image: *artifacts_uploader_image
settings:
<<: *artifacts_uploader_settings
package_version: develop
trigger-deploy-stable:
when:
- event: tag
- event: manual
branch: stable
image: *trigger_image
settings:
<<: *trigger_settings
params:
- trigger-deploy-stable.params
trigger-deploy-develop:
when:
- event: push
- event: manual
branch: ${CI_REPO_DEFAULT_BRANCH}
image: *trigger_image
settings:
<<: *trigger_settings
params:
- trigger-deploy-develop.params

View file

@ -1,47 +0,0 @@
when:
- event: pull_request
path: [ "**/*.ex", "**/*.eex", "**/*.exs", "mix.lock", ".woodpecker/**" ]
evaluate: 'CI_COMMIT_SOURCE_BRANCH != "weblate"'
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
path: [ "**/*.ex", "**/*.eex", "**/*.exs", "mix.lock", ".woodpecker/**" ]
depends_on:
- lint
labels:
platform: linux/amd64
variables:
script_file_entrypoint: &script_file_entrypoint
- /bin/sh
- -c
- 'printf "%s" "$CI_SCRIPT" | base64 -d > /tmp/ci-script.sh && /bin/sh -xe /tmp/ci-script.sh'
steps:
unit-testing-elixir-1.17:
image: elixir:1.17-otp-27-alpine
entrypoint: *script_file_entrypoint
environment:
MIX_ENV: test
VIX_COMPILATION_MODE: PLATFORM_PROVIDED_LIBVIPS
DB_HOST: postgres
DB_PORT: 5432
commands:
- apk add --no-cache build-base cmake exiftool ffmpeg vips-dev file-dev git openssl
- adduser -D -h /home/testuser testuser
- mkdir -p /home/testuser/.mix /home/testuser/.hex
- chown -R testuser:testuser . /home/testuser
- su testuser -c "HOME=/home/testuser mix local.hex --force"
- su testuser -c "HOME=/home/testuser mix local.rebar --force"
- su testuser -c "HOME=/home/testuser mix deps.get"
- su testuser -c "HOME=/home/testuser mix pleroma.test_runner --preload-modules"
services:
postgres:
image: postgres:13-alpine
failure: ignore
environment:
POSTGRES_DB: pleroma_test
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres

View file

@ -1,47 +0,0 @@
when:
- event: pull_request
path: [ "**/*.ex", "**/*.eex", "**/*.exs", "mix.lock", ".woodpecker/**" ]
evaluate: 'CI_COMMIT_SOURCE_BRANCH != "weblate"'
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
path: [ "**/*.ex", "**/*.eex", "**/*.exs", "mix.lock", ".woodpecker/**" ]
depends_on:
- lint
labels:
platform: linux/amd64
variables:
script_file_entrypoint: &script_file_entrypoint
- /bin/sh
- -c
- 'printf "%s" "$CI_SCRIPT" | base64 -d > /tmp/ci-script.sh && /bin/sh -xe /tmp/ci-script.sh'
steps:
unit-testing-elixir-1.19:
image: elixir:1.19-otp-28-alpine
entrypoint: *script_file_entrypoint
environment:
MIX_ENV: test
VIX_COMPILATION_MODE: PLATFORM_PROVIDED_LIBVIPS
DB_HOST: postgres
DB_PORT: 5432
commands:
- apk add --no-cache build-base cmake exiftool ffmpeg vips-dev file-dev git openssl
- adduser -D -h /home/testuser testuser
- mkdir -p /home/testuser/.mix /home/testuser/.hex
- chown -R testuser:testuser . /home/testuser
- su testuser -c "HOME=/home/testuser mix local.hex --force"
- su testuser -c "HOME=/home/testuser mix local.rebar --force"
- su testuser -c "HOME=/home/testuser mix deps.get"
- su testuser -c "HOME=/home/testuser mix pleroma.test_runner --preload-modules"
services:
postgres:
image: postgres:13-alpine
failure: ignore
environment:
POSTGRES_DB: pleroma_test
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres

View file

@ -4,176 +4,6 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
## 2.11.1
### Security
- Update Bandit to version 1.14.0, which fixes HTTP/1.1, HTTP/2 and WebSocket denial-of-service and request smuggling vulnerabilities
- Update Hackney to version 4.9.1, which fixes unbounded response body buffering and decompression, CA pinning, redirect credential leaks and other vulnerabilities
## 2.11.0
### Security
- Update Bandit to address HTTP request handling vulnerabilities.
- Update bandit to version 1.12.4 to fix a DoS vulnerability
- Update bandit to version 1.12.5 to fix an HTTP/2 DoS vulnerability
- Update bandit to version 1.13.1 resolving a stuck process and unvalidated HTTP/1 headers vulnerabilities
- Updated CAStore to version 1.0.22 with updated Mozilla certificate bundle after eMudhra Intermediate CA Compromise
- Update certifi to version 2.18.0, which removes the distrusted emSign roots
- Update plug_crypto to version 2.2.1, so a malformed shout socket token no longer writes the secret key base to the error log
- Update Cowboy to address multipart header parsing denial-of-service vulnerabilities.
- Update cowboy to version 2.19.0 which fixes a memory exhaustion DoS
- Update Cowlib to address HTTP parsing resource exhaustion and injection vulnerabilities.
- Update cowlib to version 2.20.0 which fixes HTTP splitting and header smuggling/injection vulnerabilities
- Update gun to version 2.7.0 and cowlib to version 2.21.0 resolving a header smuggling vulnerability
- Update Decimal and compatible dependencies to address a rounding vulnerability.
- Update Decimal to version 3.2.0 resolving an unbounded allocation vulnerability
- Replace retired Earmark rendering with the maintained EarmarkParser and an attribute-escaping renderer.
- Update gun to version 2.6.0 which fixes an HTTP request/response smuggling vulnerability
- Update Hackney and its HTTPoison integration to address SSRF, timeout, and injection vulnerabilities.
- Hackney, Finch, Mua and the Swoosh HTTP mail adapters now trust only the CAStore certificate bundle, which rejects the compromised eMudhra intermediate CAs
- Ensure Host header is present and matches instance URI
- Update mint to version 1.10.0 which fixes multiple DoS vulnerabilities
- Update mint to version 1.11.0 resolving multiple vulnerabilities
- Update Phoenix LiveView to version 1.2.9 to fix an open redirect vulnerability
- Update Phoenix to version 1.8.11 resolving a process-exhaustion DoS vulnerability
- Update Phoenix to address long-poll NDJSON request denial-of-service vulnerabilities.
- Update Plug to address multipart header parsing denial-of-service vulnerabilities.
- Update Plug.Cowboy to address HTTP/2 scheme atom exhaustion denial-of-service vulnerabilities.
- Update Postgrex to address notification channel-name SQL injection vulnerabilities.
- Update postgrex to version 0.22.4 to fix an SQL injection vulnerability
- Remove unused QUIC lockfile entry with vulnerable TLS verification behavior.
- Update swoosh to version 1.28.0 which fixes a url injection vulnerability for the Microsoft Graph adapter
- Scrubbers: remove links and images whose scheme is hidden with tabs, newlines or leading control characters (for example java<TAB>script:), which browsers still run as javascript:. Custom scrubbers should use Pleroma.HTML.URIAttributes.allow_tag_with_uri_attributes instead of the FastSanitize macro
### Changed
- Update bundled Pleroma-FE to 2.11.4
- Allow disabling Chats feature
- Pleroma now requires Elixir 1.17 or newer and Erlang/OTP 27 or newer
- Update Debian and Ubuntu installation requirements and OTP dependencies
- Update Jason to support Decimal 3 dependency resolution.
- Changed how Logger is configured due to changes in Elixir and added deprecation warnings for the old configuration format
- Update majic to 1.2.0.
- Avoid a duplicate user query during OAuth authentication.
- Use the Hex package for oban_plugins_lazarus.
- Docs OpenBSD: Increased recommended `datasize` from 1536M to 4096M to avoid Pleroma crashes
- OpenRC: Automatically run migrations before starting pleroma
- Optimize orphaned OAuth apps cleanup by deleting records in batches instead of one by one.
- Switch patched Phoenix 1.7.14 back to upstream with Phoenix 1.8.0+
- Add optional migrations for rollback from Rebased
- Use upstream Hex releases for the `remote_ip` dependency and expose client IP ranges for remote IP resolution.
- Improve user search / autocompletion ordering.
- Gun is now the default HTTP client instead of Hackney
### Added
- Allow creating accounts without a password in the AdminAPI
- Implemented ConfigDB configuration blacklist and accompanying Mix task
- Accept more real-world ActivityPub object shapes collected by fedidev.fun
- Add Mastodon-compatible grouped notifications API endpoints under `/api/v2/notifications` for newly-created notifications
- Docs: Added documentation for installing newer version of Elixir/Erlang than what distro ships
- Allow attaching emojis to user lists
- Implement basics of Mastodon admin API
- Add backend support for Misskey Markdown (MFM) posts
- Add mix_audit for dependency vulnerability checks.
- Oban: Enabled the Reindexer plugin to reduce oban_jobs index DB bloat
- Add ParadeDB (pg_search) as an optional external search backend, indexing status content, content warnings, and attachment descriptions.
- Add support for Mastodon-compatible webhooks
### Fixed
- Fixed `/api/v1/pleroma/accounts/:id/favourites` ordering and pagination to use the favourite date.
- Reject unsupported or ambiguous inbox signatures instead of queueing a doomed failed-signature retry, allowing clients to fall back to legacy HTTP Signatures.
- Switch native captcha to the published pleroma_captcha Hex package.
- Updated the captcha package to fix compilation failure on BSD-based systems
- Dockerfile: update base images to fix problems with SSL handshakes
- Docs: Fixed OTP install links in documentation, broke up wall of install commands into smaller chunks, fixed sudo commands execution
- Fix notification and timeline queries for users with domain blocks choosing a plan that scans every active user per row; the followed-accounts exception is now an `ARRAY(SELECT ...)` InitPlan that the planner costs once.
- Fixed Elixir 1.19 warnings
- Support fetching featured collection items from the first collection page
- Fix preferred frontend not working due to InstanceStatic plug prematurely returning HTTP 404
- Fixed Gun HTTP/1 concurrency, forwarding and authenticated proxy handling, tunnel requests, and streamed connection cleanup. Updated Gun and Cowlib for HTTP client security fixes.
- Stop leaking a Hackney connection process, and the response bytes it read, for every unpooled request that ends without a reusable socket
- Fix hashtag timeline query for additional tag handling
- Fix compatibility with timestamped HTTP Signatures used by GoToSocial
- Handle reports with just actor ap id as the object
- Fix Swoosh HTTP mail adapters failing with `cacerts: :undefined` on OTP 26+
- Echo Mastodon-style `Sec-WebSocket-Protocol` tokens in streaming WebSocket handshakes.
- Enforce the max_body HTTP option again, which Hackney 4 silently stopped honouring because it always returns a fully read body
- Abort incomplete media proxy responses instead of caching partial bodies.
- Updated Pleroma-FE build URL after Forgejo migration
- Fix votersCount inflation when same voter picks multiple options
- Status: Fill all MastoAPI required values in preview cards
- Avoid creating atoms from serialized PublisherWorker parameters.
- Reject incoming reports when both the reporter and reported account are remote
- Fixed account status and media views exposing activities restricted from unauthenticated users.
- Stop leaking a Hackney connection process for every media proxy response that was streamed to the end
- Fix RSS feeds to be W3C compliant and render better in RSS readers
- Keep followed users visible in streams when their domain is blocked.
- Fix intermittent failure to compile syslog package
- Fix inconsistent User cache keys and invalidate numeric ID aliases.
- Include arm32v7 in multi-arch Docker images
- RichMedia: Fix backfill causing old posts to show up on timelines by disabling it in MastoAPI StatusView
- Fix Admin-FE installation by downloading builds from the package registry instead of GitLab job artifacts.
- Hackney: use HTTP/1.1 only, so closing one media proxy response no longer breaks other downloads from the same host
- Hackney: use the configured proxy when its host is an IP address; Hackney 4 ignored such proxies and connected directly
## 2.10.2
### Security
- ActivityPub: Fixed failed-signature inbox retry handling and signer identity checks to prevent spoofed remote activities from being processed
## 2.10.1
### Changed
- Move avatar_description and header_description fields to the account object
- Update Bandit to 1.10.4
- No-op code correctness improvements detected by Elixir 1.19 compiler
- Downgrade Hackney to 1.20.1
- Use a custom redirect handler to ensure MediaProxy redirects are followed with Hackney
- Update Hackney, the default HTTP client, to the latest release which supports Happy Eyeballs for improved IPv6 federation
- Paginate follow requests
- Moved Phoenix LiveDashboard to /pleroma/live_dashboard
- Add mute/block expiry to the relationship object
- Filter indexable activities before inserting indexing jobs into the queue.
### Added
- Allow assigning users to reports
- Allow fine-grained announce visibilities
- Add immutable tag on cache-control header for several endpoints that's serving the same exact things.
- Add reasonable defaults for :database_config_whitelist
- Support lists `exclusive` param
- Add v1/instance/domain_blocks endpoint
- Add /api/v2/instance profile fields limits info used by Mastodon
- Added Oban Web dashboard located at /pleroma/oban
- Add instructions on how to run a release in docker, to make it easier to run on older distros.
### Fixed
- Fix the daily email digest job which was not executing
- Encode custom emoji URLs in EmojiReact activity tags.
- Gopher: Fix Ranch listener not being stopped properly on Pleroma restart when database configuration is enabled
- Fix fetching Hubzilla Actors with alsoKnownAs as string
- Fix /phoenix/live_dashboard redirect not working when user added a path segment
- Fix 404 error codes for missing static files
- Fix OAuth app registration to accept `redirect_uris` as an array of strings (RFC 7591), while keeping backwards compatibility with string input.
- Correct old migrations for expiring activities and user access tokens.
- Federate `votersCount` correctly
- DB prune: Check if user follows hashtag with no objects before deletion
- Stop the rate limiter from crashing when run with wrong settings.
- Restore embeds route
- ReverseProxy: Recursively follow redirects until redirect_limit is reached
- Fix compilation with vips-8.18.0 with bumping to vix 0.36.0
### Removed
- Docs: Removed outdated, incorrect, unmaintained and inappropriate installation documentation (Arch, NetBSD, NixOS)
## 2.10 ## 2.10
### Security ### Security

View file

@ -1,12 +1,10 @@
# https://hub.docker.com/r/hexpm/elixir/tags # https://hub.docker.com/r/hexpm/elixir/tags
ARG ELIXIR_IMG=hexpm/elixir ARG ELIXIR_IMG=hexpm/elixir
ARG ELIXIR_VER=1.17.3 ARG ELIXIR_VER=1.17.3
ARG ERLANG_VER=27.3.4.17 ARG ERLANG_VER=26.2.5.6
ARG ALPINE_VER=3.23.5 ARG ALPINE_VER=3.17.9
ARG ELIXIR_TAG=${ELIXIR_VER}-erlang-${ERLANG_VER}-alpine-${ALPINE_VER}
ARG ALPINE_IMG=alpine
FROM ${ELIXIR_IMG}:${ELIXIR_TAG} AS build FROM ${ELIXIR_IMG}:${ELIXIR_VER}-erlang-${ERLANG_VER}-alpine-${ALPINE_VER} AS build
COPY . . COPY . .
@ -22,7 +20,7 @@ RUN apk add git gcc g++ musl-dev make cmake file-dev vips-dev &&\
mkdir release &&\ mkdir release &&\
mix release --path release mix release --path release
FROM ${ALPINE_IMG}:${ALPINE_VER} FROM alpine:${ALPINE_VER}
ARG BUILD_DATE ARG BUILD_DATE
ARG VCS_REF ARG VCS_REF
@ -42,7 +40,7 @@ ARG HOME=/opt/pleroma
ARG DATA=/var/lib/pleroma ARG DATA=/var/lib/pleroma
RUN apk update &&\ RUN apk update &&\
apk add ffmpeg vips libmagic ncurses postgresql-client &&\ apk add exiftool ffmpeg vips libmagic ncurses postgresql-client &&\
adduser --system --shell /bin/false --home ${HOME} pleroma &&\ adduser --system --shell /bin/false --home ${HOME} pleroma &&\
mkdir -p ${DATA}/uploads &&\ mkdir -p ${DATA}/uploads &&\
mkdir -p ${DATA}/static &&\ mkdir -p ${DATA}/static &&\

View file

@ -1,61 +0,0 @@
# https://hub.docker.com/r/hexpm/elixir/tags
ARG ELIXIR_IMG=docker.io/hexpm/elixir
ARG ALPINE_IMG=docker.io/alpine
ARG ELIXIR_VER=1.18.4
ARG ERLANG_VER=27.3.4.11
ARG ALPINE_VER=3.23.4
FROM ${ELIXIR_IMG}:${ELIXIR_VER}-erlang-${ERLANG_VER}-alpine-${ALPINE_VER} AS build
COPY . .
ENV MIX_ENV=prod
ENV VIX_COMPILATION_MODE=PLATFORM_PROVIDED_LIBVIPS
RUN apk add git gcc g++ musl-dev make cmake file-dev vips-dev &&\
echo "import Config" > config/prod.secret.exs &&\
mix local.hex --force &&\
mix local.rebar --force &&\
mix deps.clean --all &&\
mix deps.get --only prod &&\
mkdir release &&\
mix release --path release
FROM ${ALPINE_IMG}:${ALPINE_VER}
ARG BUILD_DATE
ARG VCS_REF
LABEL maintainer="ops@pleroma.social" \
org.opencontainers.image.title="pleroma" \
org.opencontainers.image.description="Pleroma FE E2E test image" \
org.opencontainers.image.authors="ops@pleroma.social" \
org.opencontainers.image.vendor="pleroma.social" \
org.opencontainers.image.documentation="https://git.pleroma.social/pleroma/pleroma" \
org.opencontainers.image.licenses="AGPL-3.0" \
org.opencontainers.image.url="https://pleroma.social" \
org.opencontainers.image.revision=$VCS_REF \
org.opencontainers.image.created=$BUILD_DATE
ARG HOME=/opt/pleroma
ARG DATA=/var/lib/pleroma
RUN apk update &&\
apk add ffmpeg vips libmagic ncurses postgresql-client &&\
adduser --system --shell /bin/false --home ${HOME} pleroma &&\
mkdir -p ${DATA}/uploads &&\
mkdir -p ${DATA}/static &&\
chown -R pleroma ${DATA} &&\
mkdir -p /etc/pleroma &&\
chown -R pleroma /etc/pleroma
USER pleroma
COPY --from=build --chown=pleroma:0 /release ${HOME}
COPY --chown=pleroma --chmod=640 ./config/docker.exs /etc/pleroma/config.exs
COPY ./docker-entrypoint-e2e.sh ${HOME}
EXPOSE 4000
ENTRYPOINT ["/opt/pleroma/docker-entrypoint-e2e.sh"]

View file

@ -1,4 +1,4 @@
<img src="https://git.pleroma.social/pleroma/pleroma/raw/branch/develop/logo-with-name.png" width="300px" /> <img src="https://git.pleroma.social/pleroma/pleroma/uploads/8cec84f5a084d887339f57deeb8a293e/pleroma-banner-vector-nopad-notext.svg" width="300px" />
## About ## About

View file

@ -1 +0,0 @@
Reject remote actors whose inbox, shared inbox, followers, following or featured collection, or key id is on another host

View file

@ -1 +0,0 @@
Update ssl_verify_fun to 1.1.9 (EEF-CVE-2026-117666) and phoenix_html to 3.3.5 (EEF-CVE-2026-117645)

View file

@ -1 +0,0 @@
Check OAuth token scopes on the ActivityPub C2S endpoints; posting to the outbox with a token now needs the `write` scope

View file

@ -1 +0,0 @@
Do not crash when rendering attachments with zero width or height

View file

@ -1 +0,0 @@
Update Bandit to version 1.14.1, which fixes an HTTP/2 request body memory amplification

View file

@ -1 +0,0 @@
Rate limit ActivityPub C2S outbox posts and emoji reactions

View file

@ -1 +0,0 @@
Link preview cards skip the fallback link of quote posts (`RE: <url>`), which pointed at the quoted post and showed it twice.

View file

@ -1 +0,0 @@
Fix per-status and per-account rate limits when `Pleroma.Web.ApiSpec.CastAndValidate` `strict` is off (the production default)

View file

@ -1 +0,0 @@
Drop all unexpected query params, not just the first one, when `Pleroma.Web.ApiSpec.CastAndValidate` `strict` is off

View file

@ -1 +0,0 @@
Do not crash at boot or in the AdminAPI config listing when a ConfigDB setting refers to a module that no longer exists

View file

@ -1 +0,0 @@
Show local-only replies in status context to local users who don't follow the replier

View file

@ -1 +0,0 @@
OAuth token list API now includes property to signify which token is being used to access the API

View file

@ -1 +0,0 @@
Accept incoming emoji reactions whose tag is a single object instead of an array

View file

@ -0,0 +1 @@
Encode custom emoji URLs in EmojiReact activity tags.

View file

@ -1 +0,0 @@
HTTP: treat an empty proxy_url as no proxy; with Hackney 4 it made every outgoing request fail

View file

@ -1 +0,0 @@
Strip GPS data from WebP and HEIC/AVIF uploads; the Exiftool.StripLocation filter used to skip them; GPS data in XMP (including DJI drone positions) is stripped too

View file

@ -1 +0,0 @@
Exiftool upload filters are replaced by the built-in Exif.StripLocation and Exif.ReadDescription filters; exiftool is no longer required, old filter names still work but are deprecated

View file

@ -1 +0,0 @@
Do not deliver activities, including public ones and deletes, to instances rejected by SimplePolicy (or not on its accept list), and refuse their signed fetches in authorized fetch mode

View file

@ -1 +0,0 @@
Only accept fetched objects whose id is the URL they were fetched from; for other ids, refetch once from the canonical id on the same host

View file

@ -1 +0,0 @@
Treat filter phrases as literal text; a phrase like "(" no longer breaks timeline and notification queries, and phrases that start or end with punctuation (like "#tag") now match

View file

@ -1 +0,0 @@
Filters with whole_word set to false now also match inside words

View file

@ -1 +0,0 @@
Reject fetched objects whose author has no id instead of crashing

View file

@ -1 +0,0 @@
gin_fuzzy_search_limit is now only set for search queries (configurable under Pleroma.Search.DatabaseSearch), so other GIN index scans such as recipient lookups and Oban job queries are exact again

View file

@ -1 +0,0 @@
Gun adapter: connect to hosts that only have IPv6 (AAAA) addresses

View file

@ -0,0 +1 @@
Use a custom redirect handler to ensure MediaProxy redirects are followed with Hackney

View file

@ -0,0 +1 @@
Update Hackney, the default HTTP client, to the latest release which supports Happy Eyeballs for improved IPv6 federation

View file

@ -1 +0,0 @@
Back off from hosts that answer 429 or 503 to object fetches and WebFinger, until Retry-After or X-RateLimit-Reset (default 5 minutes, max 1 hour)

View file

@ -0,0 +1 @@
Docs: Removed outdated, incorrect, unmaintained and inappropriate installation documentation (Arch, NetBSD, NixOS)

View file

@ -0,0 +1 @@
Add v1/instance/domain_blocks endpoint

View file

@ -1 +0,0 @@
Update jose to version 1.11.13, which fixes JWE, key parsing and signature validation vulnerabilities

View file

@ -1 +0,0 @@
Delete legacy Postgres sequences for activities, chats, and users which were converted to Flake IDs

View file

@ -1 +0,0 @@
Mastodon API: Use the Mastodon date format for marker updated_at

View file

@ -1 +0,0 @@
Add the Mastodon quote entity (`quote` with `state` and `quoted_status`) to statuses, so Mastodon 4.4+ clients show quote posts

View file

@ -1 +0,0 @@
MediaProxy: Do not proxy data: URLs

View file

@ -1 +0,0 @@
Proxy media given as network-path URLs (//host/path), so remote HTML cannot load images directly

View file

@ -1 +0,0 @@
Media proxy: serve a preview for static=true on non-GIF files instead of redirecting to the main endpoint host

View file

@ -1 +0,0 @@
Do not notify tagged users who cannot see the post

View file

@ -1 +0,0 @@
Accept a Move when the cached remote target does not list the alias yet, by refetching the target once

View file

@ -1 +0,0 @@
MRF domain rules now match dots literally, so a rule for `good.example` no longer also matches `goodxexample`, and wildcard rules no longer backtrack on hostile host names

View file

@ -1 +0,0 @@
Do not crash when creating notifications for posts without content while the user has filters

View file

@ -1 +0,0 @@
Support the Mastodon `profile` OAuth scope, which only gives the public account from verify_credentials

View file

@ -0,0 +1 @@
Fix OAuth app registration to accept `redirect_uris` as an array of strings (RFC 7591), while keeping backwards compatibility with string input.

View file

@ -1 +0,0 @@
Require the read:security and write:security scopes to list and revoke OAuth tokens (HTTP Basic auth no longer works for these endpoints)

1
changelog.d/oban-web.add Normal file
View file

@ -0,0 +1 @@
Added Oban Web dashboard located at /pleroma/oban

View file

@ -1 +0,0 @@
ObjectAgePolicy no longer makes old DMs and followers-only posts public

View file

@ -0,0 +1 @@
Paginate follow requests

View file

@ -1 +0,0 @@
Accept activities delivered to a personal inbox that do not address the inbox owner (fixes Bridgy Fed follows)

View file

@ -0,0 +1 @@
Moved Phoenix LiveDashboard to /pleroma/live_dashboard

View file

@ -1 +0,0 @@
Apply the Note fixups to incoming Questions, so polls with a single non-array tag or attachment are accepted

View file

@ -0,0 +1 @@
Reduce the number of flaky tests by making them sync if they affect the global state, and silence noisy test output.

View file

@ -1 +0,0 @@
Do not let a refetched object (such as a poll) change its id or author

View file

@ -0,0 +1 @@
Add instructions on how to run a release in docker, to make it easier to run on older distros.

View file

@ -1 +0,0 @@
Add a bounded retention mode (`config :pleroma, :retention`): a cron worker walks old activities in id order and evicts remote threads nobody local interacted with, in bounded batches, so the database plateaus instead of growing forever. Adds a `retention_cursors` table. `prune_objects --keep-threads` now also keeps threads that are addressed to a local user, still have a notification for one, contain a post quoted by a local post, or contain a reported post.

View file

@ -1 +0,0 @@
Status search only fetches remote URLs with resolve=true, on the first page, and for anonymous users only if limit_to_local_content allows it

View file

@ -1 +0,0 @@
Deliver to shared inboxes whenever possible, including followers-only posts and DMs, so each server gets one copy

View file

@ -1 +0,0 @@
Reject incoming HTTP signatures that do not sign the date, are older than 2 hours (or more than 1 hour in the future), or do not sign the digest of a request body, so captured requests cannot be replayed. Set `config :pleroma, :activitypub, signature_policy: :log` to only log these

View file

@ -1 +0,0 @@
Read the peer list from the instances table (hosts of remote actors, without our own host) and update instance stats every 5 minutes; the old peers query scanned all remote users every minute

View file

@ -1 +0,0 @@
Rate limit favourites and reblogs per status, not across all statuses

View file

@ -1 +0,0 @@
Added "last active at" field to OAuth token management

View file

@ -1 +0,0 @@
Do not federate the Undo of a block when `outgoing_blocks` is disabled

View file

@ -1 +0,0 @@
Update the known user instead of failing when an actor is fetched from a display URL

View file

@ -1 +0,0 @@
Added information about duplicates and usage when fetching attachments and allow to delete said attachments via `DELETE /api/v1/media/:id`

View file

@ -1 +0,0 @@
Fix deactivated users being counted in followers collections and getting admin emails, because User.Query ignored the is_active key

View file

@ -0,0 +1 @@
Fix compilation with vips-8.18.0 with bumping to vix 0.36.0

View file

@ -64,9 +64,9 @@ config :pleroma, Pleroma.Upload,
link_name: false, link_name: false,
proxy_remote: false, proxy_remote: false,
filename_display_max_length: 30, filename_display_max_length: 30,
default_description: nil, default_description: :filename,
base_url: nil, base_url: nil,
allowed_mime_types: ["image", "audio", "video"] allowed_mime_types: ["image", "audio", "video", "application"]
config :pleroma, Pleroma.Uploaders.Local, uploads: "uploads" config :pleroma, Pleroma.Uploaders.Local, uploads: "uploads"
@ -133,17 +133,13 @@ config :pleroma, Pleroma.Web.Endpoint,
] ]
# Configures Elixir's Logger # Configures Elixir's Logger
# Primary config config :logger, backends: [:console]
config :logger, level: :debug
# Console config config :logger, :console,
config :logger, :default_handler, level: :debug level: :debug,
config :logger, :default_formatter,
format: "\n$time $metadata[$level] $message\n", format: "\n$time $metadata[$level] $message\n",
metadata: [:actor, :path, :type, :user] metadata: [:actor, :path, :type, :user]
# Syslog config
config :logger, :ex_syslogger, config :logger, :ex_syslogger,
level: :debug, level: :debug,
ident: "pleroma", ident: "pleroma",
@ -161,11 +157,7 @@ config :mime, :types, %{
"image/apng" => ["apng"] "image/apng" => ["apng"]
} }
config :tesla, adapter: Tesla.Adapter.Gun config :tesla, adapter: Tesla.Adapter.Hackney
# Hackney 4 shares one HTTP/2 connection per host, and closing one response
# (as the media proxy does) stops it for every other stream on it.
config :hackney, default_protocols: [:http1]
# Configures http settings, upstream proxy etc. # Configures http settings, upstream proxy etc.
config :pleroma, :http, config :pleroma, :http,
@ -175,18 +167,18 @@ config :pleroma, :http,
adapter: [] adapter: []
config :pleroma, :instance, config :pleroma, :instance,
name: "Pleroma", name: "Shigusegubu",
email: "example@example.com", email: "pleroma@hjkos.com",
notify_email: "noreply@example.com", notify_email: "pleroma@hjkos.com",
description: "Pleroma: An efficient and flexible fediverse server", description: "SigSegV, a pleroma instance",
short_description: "", short_description: "HJ's semi-personal instance",
background_image: "/images/city.jpg", background_image: "/images/city.jpg",
instance_thumbnail: "/instance/thumbnail.jpeg", instance_thumbnail: "/instance/thumbnail.jpeg",
favicon: "/favicon.png", favicon: "/favicon.png",
limit: 5_000, limit: 5_000,
description_limit: 5_000, description_limit: 5_000,
remote_limit: 100_000, remote_limit: 100_000,
upload_limit: 16_000_000, upload_limit: 200_000_000,
avatar_upload_limit: 2_000_000, avatar_upload_limit: 2_000_000,
background_upload_limit: 4_000_000, background_upload_limit: 4_000_000,
banner_upload_limit: 4_000_000, banner_upload_limit: 4_000_000,
@ -204,20 +196,17 @@ config :pleroma, :instance,
federation_incoming_replies_max_depth: 100, federation_incoming_replies_max_depth: 100,
allow_relay: true, allow_relay: true,
public: true, public: true,
quarantined_instances: [], quarantined_instances: [{ "pleroma.rareome.ga", "leaks private posts or sumshit i dont rember" }],
rejected_instances: [], rejected_instances: [],
static_dir: "instance/static/", static_dir: "instance/static/",
allowed_post_formats: [ allowed_post_formats: [
"text/plain", "text/plain",
"text/html", "text/bbcode"
"text/markdown",
"text/bbcode",
"text/x.misskeymarkdown"
], ],
autofollowed_nicknames: [], autofollowed_nicknames: [],
autofollowing_nicknames: [], autofollowing_nicknames: [],
max_pinned_statuses: 1, max_pinned_statuses: 1,
attachment_links: false, attachment_links: true,
max_report_comment_size: 1000, max_report_comment_size: 1000,
report_strip_status: true, report_strip_status: true,
safe_dm_mentions: false, safe_dm_mentions: false,
@ -310,8 +299,8 @@ config :pleroma, :markup,
config :pleroma, :frontend_configurations, config :pleroma, :frontend_configurations,
pleroma_fe: %{ pleroma_fe: %{
alwaysShowSubjectInput: true, alwaysShowSubjectInput: false,
background: "/images/city.jpg", background: "/static/sigsegv_s.png",
collapseMessageWithSubject: false, collapseMessageWithSubject: false,
disableChat: false, disableChat: false,
greentext: false, greentext: false,
@ -325,18 +314,18 @@ config :pleroma, :frontend_configurations,
logo: "/static/logo.svg", logo: "/static/logo.svg",
logoMargin: ".1em", logoMargin: ".1em",
logoMask: true, logoMask: true,
minimalScopesMode: false, minimalScopesMode: true,
noAttachmentLinks: false, noAttachmentLinks: false,
nsfwCensorImage: "", nsfwCensorImage: "",
postContentType: "text/plain", postContentType: "text/plain",
redirectRootLogin: "/main/friends", redirectRootLogin: "/main/friends",
redirectRootNoLogin: "/main/all", redirectRootNoLogin: "/main/all",
scopeCopy: true, scopeCopy: false,
sidebarRight: false, sidebarRight: false,
showFeaturesPanel: true, showFeaturesPanel: true,
showInstanceSpecificPanel: false, showInstanceSpecificPanel: true,
subjectLineBehavior: "email", subjectLineBehavior: "noop",
theme: "pleroma-dark", theme: "sigsegv2",
webPushNotifications: false webPushNotifications: false
} }
@ -373,9 +362,6 @@ config :pleroma, :activitypub,
note_replies_output_limit: 5, note_replies_output_limit: 5,
sign_object_fetches: true, sign_object_fetches: true,
authorized_fetch_mode: false, authorized_fetch_mode: false,
signature_policy: :enforce,
signature_max_age: 7200,
signature_max_clock_skew: 3600,
client_api_enabled: false, client_api_enabled: false,
anonymize_reporter: false, anonymize_reporter: false,
anonymize_reporter_local_nickname: "" anonymize_reporter_local_nickname: ""
@ -398,8 +384,23 @@ config :pleroma, :mrf_hellthread,
config :pleroma, :mrf_simple, config :pleroma, :mrf_simple,
media_removal: [], media_removal: [],
media_nsfw: [], media_nsfw: [
federated_timeline_removal: [], { "preteengirls.biz", "pron or even cp" },
{ "melalandia.tk", "i don't rember" },
{ "pl.smuglo.li", "instance is dead but i still remember, rip smuglo" },
{ "baraag.net", "pron" },
{ "humblr.social", "3dpd pron" },
{ "pawoo.net", "tasteful pron, mostly." },
{ "sinblr.com", "3dpd pron" }
],
federated_timeline_removal: [
{ "preteengirls.biz", "pron or even cp" },
{ "melalandia.tk", "i don't rember" },
{ "baraag.net", "pron" },
{ "humblr.social", "3dpd pron" },
{ "pawoo.net", "tasteful pron, mostly." },
{ "sinblr.com", "3dpd pron" }
],
report_removal: [], report_removal: [],
reject: [], reject: [],
followers_only: [], followers_only: [],
@ -510,7 +511,7 @@ config :pleroma, :media_preview_proxy,
min_content_length: 100 * 1024 min_content_length: 100 * 1024
config :pleroma, :shout, config :pleroma, :shout,
enabled: true, enabled: false,
limit: 5_000 limit: 5_000
config :phoenix, :format_encoders, json: Jason, "activity+json": Jason config :phoenix, :format_encoders, json: Jason, "activity+json": Jason
@ -614,16 +615,11 @@ config :pleroma, Oban,
search_indexing: [limit: 10, paused: true], search_indexing: [limit: 10, paused: true],
slow: 5 slow: 5
], ],
plugins: [ plugins: [Oban.Plugins.Lazarus, {Oban.Plugins.Pruner, max_age: 900}],
Oban.Plugins.Lazarus,
{Oban.Plugins.Pruner, max_age: 900},
{Oban.Plugins.Reindexer, schedule: "@weekly"}
],
crontab: [ crontab: [
{"0 0 * * 0", Pleroma.Workers.Cron.DigestEmailsWorker}, {"0 0 * * 0", Pleroma.Workers.Cron.DigestEmailsWorker},
{"0 0 * * *", Pleroma.Workers.Cron.NewUsersDigestWorker}, {"0 0 * * *", Pleroma.Workers.Cron.NewUsersDigestWorker},
{"*/10 * * * *", Pleroma.Workers.Cron.AppCleanupWorker}, {"*/10 * * * *", Pleroma.Workers.Cron.AppCleanupWorker}
{"0 * * * *", Pleroma.Workers.Cron.RetentionWorker}
] ]
config :pleroma, Pleroma.Formatter, config :pleroma, Pleroma.Formatter,
@ -754,7 +750,6 @@ config :pleroma, Pleroma.Workers.PurgeExpiredActivity, enabled: true, min_lifeti
config :pleroma, Pleroma.Web.Plugs.RemoteIp, config :pleroma, Pleroma.Web.Plugs.RemoteIp,
enabled: true, enabled: true,
headers: ["x-forwarded-for"], headers: ["x-forwarded-for"],
clients: [],
proxies: [], proxies: [],
reserved: [ reserved: [
"127.0.0.0/8", "127.0.0.0/8",
@ -793,7 +788,7 @@ config :pleroma, :frontends,
"name" => "pleroma-fe", "name" => "pleroma-fe",
"git" => "https://git.pleroma.social/pleroma/pleroma-fe", "git" => "https://git.pleroma.social/pleroma/pleroma-fe",
"build_url" => "build_url" =>
"https://git.pleroma.social/api/packages/pleroma/generic/pleroma-fe-builds/${ref}/latest.zip", "https://git.pleroma.social/pleroma/pleroma-fe/-/jobs/artifacts/${ref}/download?job=build",
"ref" => "develop" "ref" => "develop"
}, },
"fedi-fe" => %{ "fedi-fe" => %{
@ -810,7 +805,7 @@ config :pleroma, :frontends,
"name" => "admin-fe", "name" => "admin-fe",
"git" => "https://git.pleroma.social/pleroma/admin-fe", "git" => "https://git.pleroma.social/pleroma/admin-fe",
"build_url" => "build_url" =>
"https://git.pleroma.social/api/packages/pleroma/generic/admin-fe-builds/${ref}/latest.zip", "https://git.pleroma.social/pleroma/admin-fe/-/jobs/artifacts/${ref}/download?job=build",
"ref" => "develop" "ref" => "develop"
}, },
"soapbox" => %{ "soapbox" => %{
@ -844,10 +839,10 @@ config :pleroma, :web_cache_ttl,
config :pleroma, :modules, runtime_dir: "instance/modules" config :pleroma, :modules, runtime_dir: "instance/modules"
config :pleroma, configurable_from_database: false config :pleroma, configurable_from_database: true
config :pleroma, Pleroma.Repo, config :pleroma, Pleroma.Repo,
parameters: [jit: "off"], parameters: [gin_fuzzy_search_limit: "500", jit: "off"],
prepare: :unnamed prepare: :unnamed
config :pleroma, :connections_pool, config :pleroma, :connections_pool,
@ -917,9 +912,13 @@ config :pleroma, Pleroma.Web.ApiSpec.CastAndValidate, strict: false
config :pleroma, :mrf, config :pleroma, :mrf,
policies: [ policies: [
Pleroma.Web.ActivityPub.MRF.ObjectAgePolicy, Pleroma.Web.ActivityPub.MRF.SimplePolicy,
Pleroma.Web.ActivityPub.MRF.HellthreadPolicy,
Pleroma.Web.ActivityPub.MRF.AntiFollowbotPolicy,
Pleroma.Web.ActivityPub.MRF.TagPolicy, Pleroma.Web.ActivityPub.MRF.TagPolicy,
Pleroma.Web.ActivityPub.MRF.InlineQuotePolicy Pleroma.Web.ActivityPub.MRF.ObjectAgePolicy,
Pleroma.Web.ActivityPub.MRF.InlineQuotePolicy,
Pleroma.Web.ActivityPub.MRF.AntiLinkSpamPolicy
], ],
transparency: true, transparency: true,
transparency_exclusions: [] transparency_exclusions: []
@ -932,12 +931,6 @@ config :web_push_encryption, http_client: Pleroma.HTTP.WebPush
config :pleroma, :instances_favicons, enabled: false config :pleroma, :instances_favicons, enabled: false
config :pleroma, :retention,
enabled: false,
max_objects: nil,
batch_size: 50_000,
keep_non_public: false
config :floki, :html_parser, Floki.HTMLParser.FastHtml config :floki, :html_parser, Floki.HTMLParser.FastHtml
config :pleroma, Pleroma.Web.Auth.Authenticator, Pleroma.Web.Auth.PleromaAuthenticator config :pleroma, Pleroma.Web.Auth.Authenticator, Pleroma.Web.Auth.PleromaAuthenticator
@ -950,30 +943,18 @@ config :pleroma, Pleroma.User.Backup,
timeout: :timer.minutes(30) timeout: :timer.minutes(30)
config :pleroma, ConcurrentLimiter, [ config :pleroma, ConcurrentLimiter, [
{Pleroma.Search, [max_running: 30, max_waiting: 50]}, {Pleroma.Search, [max_running: 30, max_waiting: 50]}
{Pleroma.Webhook.Notify, [max_running: 5, max_waiting: 200]}
] ]
config :pleroma, Pleroma.Web.WebFinger, domain: nil, update_nickname_on_user_fetch: true config :pleroma, Pleroma.Web.WebFinger, domain: nil, update_nickname_on_user_fetch: true
config :pleroma, Pleroma.Search, module: Pleroma.Search.DatabaseSearch config :pleroma, Pleroma.Search, module: Pleroma.Search.DatabaseSearch
config :pleroma, Pleroma.Search.DatabaseSearch, gin_fuzzy_search_limit: 500
config :pleroma, Pleroma.Search.Meilisearch, config :pleroma, Pleroma.Search.Meilisearch,
url: "http://127.0.0.1:7700/", url: "http://127.0.0.1:7700/",
private_key: nil, private_key: nil,
initial_indexing_chunk_size: 100_000 initial_indexing_chunk_size: 100_000
config :pleroma, Pleroma.Search.ParadeDB,
url: nil,
table: "pleroma_search_documents",
fuzzy_distance: 0
config :pleroma, Pleroma.Search.ParadeDB.Repo,
pool_size: 2,
prepare: :unnamed
config :pleroma, Pleroma.Application, config :pleroma, Pleroma.Application,
background_migrators: true, background_migrators: true,
internal_fetch: true, internal_fetch: true,
@ -996,21 +977,6 @@ config :pleroma, Pleroma.Search.QdrantSearch,
vectors: %{size: 384, distance: "Cosine"} vectors: %{size: 384, distance: "Cosine"}
} }
config :pleroma, :database_config_blacklist, [
{:pleroma, :logger}
]
config :pleroma, :database_config_whitelist, [
{:pleroma},
{:cors_plug},
{:ex_aws, :s3},
{:mime},
{:prometheus, Pleroma.Web.Endpoint.MetricsExporter},
{:web_push_encryption, :vapid_details}
]
config :pleroma, Pleroma.Chat, enabled: true
# Import environment specific config. This must remain at the bottom # Import environment specific config. This must remain at the bottom
# of this file so it overrides the configuration defined above. # of this file so it overrides the configuration defined above.
import_config "#{Mix.env()}.exs" import_config "#{Mix.env()}.exs"

View file

@ -815,8 +815,7 @@ config :pleroma, :config_description, [
"text/plain", "text/plain",
"text/html", "text/html",
"text/markdown", "text/markdown",
"text/bbcode", "text/bbcode"
"text/x.misskeymarkdown"
] ]
}, },
%{ %{
@ -1395,13 +1394,7 @@ config :pleroma, :config_description, [
label: "Post Content Type", label: "Post Content Type",
type: {:dropdown, :atom}, type: {:dropdown, :atom},
description: "Default post formatting option", description: "Default post formatting option",
suggestions: [ suggestions: ["text/plain", "text/html", "text/markdown", "text/bbcode"]
"text/plain",
"text/html",
"text/markdown",
"text/bbcode",
"text/x.misskeymarkdown"
]
}, },
%{ %{
key: :redirectRootNoLogin, key: :redirectRootNoLogin,
@ -1788,27 +1781,6 @@ config :pleroma, :config_description, [
description: description:
"List of IPs (CIDR format accepted) to exempt from HTTP Signatures requirement (for example to allow debugging, you shouldn't otherwise need this)" "List of IPs (CIDR format accepted) to exempt from HTTP Signatures requirement (for example to allow debugging, you shouldn't otherwise need this)"
}, },
%{
key: :signature_policy,
type: {:dropdown, :atom},
description:
"What to do with incoming HTTP signatures that do not sign the date (or `(created)`), are outside the allowed time window, or do not sign the digest of a request body. `:enforce` treats them as invalid, `:log` only logs them",
suggestions: [:enforce, :log]
},
%{
key: :signature_max_age,
type: :integer,
description:
"How old, in seconds, the signed date of an incoming HTTP signature can be. Default: 7200 (2 hours)",
suggestions: [7200]
},
%{
key: :signature_max_clock_skew,
type: :integer,
description:
"How far, in seconds, the signed date of an incoming HTTP signature can be in the future. Default: 3600 (1 hour). A `(created)` time in the future is always rejected",
suggestions: [3600]
},
%{ %{
key: :note_replies_output_limit, key: :note_replies_output_limit,
type: :integer, type: :integer,
@ -2747,19 +2719,6 @@ config :pleroma, :config_description, [
} }
] ]
}, },
%{
group: :pleroma,
key: Pleroma.Chat,
type: :group,
description: "Pleroma Chat settings",
children: [
%{
key: :enabled,
type: :boolean,
description: "Enables the chats API."
}
]
},
%{ %{
group: :pleroma, group: :pleroma,
key: :http, key: :http,
@ -2944,7 +2903,7 @@ config :pleroma, :config_description, [
key: Pleroma.Web.Plugs.RemoteIp, key: Pleroma.Web.Plugs.RemoteIp,
type: :group, type: :group,
description: """ description: """
`Pleroma.Web.Plugs.RemoteIp` is a shim to call [`RemoteIp`](https://hex.pm/packages/remote_ip) but with runtime configuration. `Pleroma.Web.Plugs.RemoteIp` is a shim to call [`RemoteIp`](https://git.pleroma.social/pleroma/remote_ip) but with runtime configuration.
**If your instance is not behind at least one reverse proxy, you should not enable this plug.** **If your instance is not behind at least one reverse proxy, you should not enable this plug.**
""", """,
children: [ children: [
@ -2960,12 +2919,6 @@ config :pleroma, :config_description, [
A list of strings naming the HTTP headers to use when deriving the true client IP. Default: `["x-forwarded-for"]`. A list of strings naming the HTTP headers to use when deriving the true client IP. Default: `["x-forwarded-for"]`.
""" """
}, },
%{
key: :clients,
type: {:list, :string},
description:
"A list of client IPs or subnets in CIDR notation. These will not be treated as proxies or reserved ranges. Defaults to `[]`. IPv4 entries without a bitmask will be assumed to be /32 and IPv6 /128."
},
%{ %{
key: :proxies, key: :proxies,
type: {:list, :string}, type: {:list, :string},
@ -3119,16 +3072,9 @@ config :pleroma, :config_description, [
%{ %{
key: :max_connections, key: :max_connections,
type: :integer, type: :integer,
description: description: "Maximum number of connections in the pool. Default: 250 connections.",
"Maximum total number of connections in the pool. HTTP/1 origins may use multiple connections within this limit, while HTTP/2 connections are multiplexed. Default: 250 connections.",
suggestions: [250] suggestions: [250]
}, },
%{
key: :max_idle_time,
type: :integer,
description: "Time before an unused connection is closed. Default: 30000ms.",
suggestions: [30_000]
},
%{ %{
key: :connect_timeout, key: :connect_timeout,
type: :integer, type: :integer,
@ -3331,42 +3277,6 @@ config :pleroma, :config_description, [
} }
] ]
}, },
%{
group: :pleroma,
key: :retention,
type: :group,
description:
"Bounded retention: continuously evict old remote threads nobody local interacted with." <>
" Local posts and threads with local interactions are always kept.",
children: [
%{
key: :enabled,
type: :boolean,
description: "Run the retention worker from the Oban crontab"
},
%{
key: :max_objects,
type: :integer,
description:
"Optional watermark. When the objects table is estimated to hold more rows than this," <>
" the oldest unpinned remote threads quiet for more than a day are evicted, whatever the retention period.",
suggestions: [nil, 1_000_000]
},
%{
key: :batch_size,
type: :integer,
description:
"Number of activities the worker walks per run; their threads are checked and evicted." <>
" Default: 50000.",
suggestions: [50_000]
},
%{
key: :keep_non_public,
type: :boolean,
description: "Also keep threads that contain non-public posts"
}
]
},
%{ %{
group: :ex_aws, group: :ex_aws,
key: :s3, key: :s3,
@ -3580,26 +3490,6 @@ config :pleroma, :config_description, [
suggestion: [5] suggestion: [5]
} }
] ]
},
%{
key: Pleroma.Webhook.Notify,
type: :keyword,
description: "Concurrent limits configuration for webhooks.",
suggestions: [max_running: 5, max_waiting: 200],
children: [
%{
key: :max_running,
type: :integer,
description: "Max running concurrently jobs.",
suggestion: [5]
},
%{
key: :max_waiting,
type: :integer,
description: "Max waiting jobs.",
suggestion: [200]
}
]
} }
] ]
}, },
@ -3613,27 +3503,7 @@ config :pleroma, :config_description, [
key: :module, key: :module,
type: :keyword, type: :keyword,
description: "Selected search module.", description: "Selected search module.",
suggestion: [ suggestion: [Pleroma.Search.DatabaseSearch, Pleroma.Search.Meilisearch]
Pleroma.Search.DatabaseSearch,
Pleroma.Search.Meilisearch,
Pleroma.Search.QdrantSearch,
Pleroma.Search.ParadeDB
]
}
]
},
%{
group: :pleroma,
key: Pleroma.Search.DatabaseSearch,
type: :group,
description: "Built-in database search settings.",
children: [
%{
key: :gin_fuzzy_search_limit,
type: :integer,
description:
"Limits how many matches PostgreSQL considers in GIN full-text search queries (see `gin_fuzzy_search_limit` in the PostgreSQL docs). Only set for search queries. Keeps search fast on large databases, but results become incomplete and change between requests. Set to `nil` for exact results, which is fine on small instances. Default: 500.",
suggestions: [500, nil]
} }
] ]
}, },
@ -3666,34 +3536,6 @@ config :pleroma, :config_description, [
} }
] ]
}, },
%{
group: :pleroma,
key: Pleroma.Search.ParadeDB,
type: :group,
description: "ParadeDB settings.",
children: [
%{
key: :url,
type: :string,
description:
"ParadeDB database URL (separate Postgres instance). " <>
"Can also be set via `PARADEDB_DATABASE_URL`.",
suggestion: ["postgres://postgres:postgres@127.0.0.1:5432/paradedb"]
},
%{
key: :table,
type: :string,
description: "Table name used for search documents.",
suggestion: ["pleroma_search_documents"]
},
%{
key: :fuzzy_distance,
type: :integer,
description: "Edit-distance used for fuzzy token matching (0 disables fuzziness, max 2).",
suggestion: [0, 1, 2]
}
]
},
%{ %{
group: :pleroma, group: :pleroma,
key: Pleroma.Language.LanguageDetector, key: Pleroma.Language.LanguageDetector,

View file

@ -36,7 +36,7 @@ config :pleroma, Pleroma.Emails.Mailer, adapter: Swoosh.Adapters.Local
# different ports. # different ports.
# Do not include timestamps in development logs # Do not include timestamps in development logs
config :logger, :default_formatter, format: "$metadata[$level] $message\n" config :logger, Logger.Backends.Console, format: "$metadata[$level] $message\n"
# Set a higher stacktrace during development. Avoid configuring such # Set a higher stacktrace during development. Avoid configuring such
# in production as building large stacktraces may be expensive. # in production as building large stacktraces may be expensive.

View file

@ -20,7 +20,8 @@ config :pleroma, Pleroma.Web.Endpoint,
config :phoenix, serve_endpoints: true config :phoenix, serve_endpoints: true
# Do not print debug messages in production # Do not print debug messages in production
config :logger, :default_handler, level: :info config :logger, Logger.Backends.Console, level: :info
config :logger, :console, level: :info
config :logger, :ex_syslogger, level: :info config :logger, :ex_syslogger, level: :info
# ## SSL Support # ## SSL Support

View file

@ -15,11 +15,9 @@ config :pleroma, Pleroma.Captcha,
method: Pleroma.Captcha.Mock method: Pleroma.Captcha.Mock
# Print only warnings and errors during test # Print only warnings and errors during test
config :logger, :default_handler, level: :warning config :logger, :console,
level: :warning,
config :logger, :default_formatter, format: "\n[$level] $message\n"
format: "\n[$level] $message\n",
colors: [enabled: false]
config :pleroma, :auth, oauth_consumer_strategies: [] config :pleroma, :auth, oauth_consumer_strategies: []

View file

@ -1,70 +0,0 @@
#!/bin/ash
set -eu
SEED_SENTINEL_PATH=/var/lib/pleroma/.e2e_seeded
CONFIG_OVERRIDE_PATH=/var/lib/pleroma/config.exs
echo '-- Waiting for database...'
while ! pg_isready -U "${DB_USER:-pleroma}" -d "postgres://${DB_HOST:-db}:${DB_PORT:-5432}/${DB_NAME:-pleroma}" -t 1; do
sleep 1s
done
echo '-- Writing E2E config overrides...'
cat > "$CONFIG_OVERRIDE_PATH" <<EOF
import Config
config :pleroma, Pleroma.Captcha,
enabled: false
config :pleroma, :instance,
registrations_open: true,
account_activation_required: false,
account_approval_required: false
EOF
echo '-- Running migrations...'
/opt/pleroma/bin/pleroma_ctl migrate
if [ ! -f "$SEED_SENTINEL_PATH" ]; then
if [ -n "${E2E_ADMIN_USERNAME:-}" ] && [ -n "${E2E_ADMIN_PASSWORD:-}" ] && [ -n "${E2E_ADMIN_EMAIL:-}" ]; then
echo '-- Seeding admin user' "$E2E_ADMIN_USERNAME" '...'
if ! PLEROMA_CTL_RPC_DISABLED=true /opt/pleroma/bin/pleroma_ctl user new "$E2E_ADMIN_USERNAME" "$E2E_ADMIN_EMAIL" --admin --password "$E2E_ADMIN_PASSWORD" -y; then
echo '-- User already exists or creation failed, ensuring admin + confirmed...'
PLEROMA_CTL_RPC_DISABLED=true /opt/pleroma/bin/pleroma_ctl user set "$E2E_ADMIN_USERNAME" --admin --confirmed
fi
else
echo '-- Skipping admin seeding (missing E2E_ADMIN_* env)'
fi
touch "$SEED_SENTINEL_PATH"
fi
echo '-- Starting!'
/opt/pleroma/bin/pleroma start &
PLEROMA_PID=$!
cleanup() {
if kill -0 "$PLEROMA_PID" 2>/dev/null; then
kill -TERM "$PLEROMA_PID"
wait "$PLEROMA_PID" || true
fi
}
trap cleanup INT TERM
echo '-- Waiting for API...'
api_ok=false
for _i in $(seq 1 120); do
if wget -qO- http://127.0.0.1:4000/api/v1/instance >/dev/null 2>&1; then
api_ok=true
break
fi
sleep 1s
done
if [ "$api_ok" != true ]; then
echo 'Timed out waiting for Pleroma API to become available'
exit 1
fi
wait "$PLEROMA_PID"

View file

@ -169,18 +169,4 @@ This forcibly removes any enabled MRF that does not exist and will fix the abili
=== "From Source" === "From Source"
```sh ```sh
mix pleroma.config fix_mrf_policies mix pleroma.config fix_mrf_policies
``` ```
## Remove non-whitelisted configs from the database
This removes any configuration value that is not explicitly whitelisted by `:pleroma, :database_config_whitelist`. Might be useful after updating the whitelist.
=== "OTP"
```sh
./bin/pleroma_ctl config filter_whitelisted
```
=== "From Source"
```sh
mix pleroma.config filter_whitelisted
```

View file

@ -28,9 +28,6 @@ Replaces embedded objects with references to them in the `objects` table. Only n
This will prune remote posts older than 90 days (configurable with [`config :pleroma, :instance, remote_post_retention_days`](../../configuration/cheatsheet.md#instance)) from the database. Pruned posts may be refetched in some cases. This will prune remote posts older than 90 days (configurable with [`config :pleroma, :instance, remote_post_retention_days`](../../configuration/cheatsheet.md#instance)) from the database. Pruned posts may be refetched in some cases.
!!! tip
To keep the database bounded continuously instead of pruning in one go, see [`:retention`](../../configuration/cheatsheet.md#retention). It uses the same rules as `--keep-threads` but runs in small batches from a cron worker.
!!! note !!! note
The disk space will only be reclaimed after a proper vacuum. By default Postgresql does this for you on a regular basis, but if your instance has been running for a long time and there are many rows deleted, it may be advantageous to use `VACUUM FULL` (e.g. by using the `--vacuum` option). The disk space will only be reclaimed after a proper vacuum. By default Postgresql does this for you on a regular basis, but if your instance has been running for a long time and there are many rows deleted, it may be advantageous to use `VACUUM FULL` (e.g. by using the `--vacuum` option).

View file

@ -76,22 +76,6 @@ The resulting frontend will always be installed into a folder of this template:
Careful: This folder will be completely replaced on installation. Careful: This folder will be completely replaced on installation.
## Installing Admin-FE
=== "OTP"
```sh
./bin/pleroma_ctl frontend install admin-fe --ref stable
```
=== "From Source"
```sh
mix pleroma.frontend install admin-fe --ref stable
```
Builds come from the package registry: `https://git.pleroma.social/api/packages/pleroma/generic/admin-fe-builds/${ref}/latest.zip`. `stable` and `develop` are published; `stable` is the better choice for production. A release tag works as `--ref` once a build for it is published.
## Example installation for an unknown frontend ## Example installation for an unknown frontend
The installation process is the same, but you will have to give all the needed options on the command line. For example: The installation process is the same, but you will have to give all the needed options on the command line. For example:

View file

@ -37,8 +37,8 @@ If any of the options are left unspecified, you will be prompted interactively.
- `--static-dir <path>` - the directory custom public files should be read from (custom emojis, frontend bundle overrides, robots.txt, etc.) - `--static-dir <path>` - the directory custom public files should be read from (custom emojis, frontend bundle overrides, robots.txt, etc.)
- `--listen-ip <ip>` - the ip the app should listen to, defaults to 127.0.0.1 - `--listen-ip <ip>` - the ip the app should listen to, defaults to 127.0.0.1
- `--listen-port <port>` - the port the app should listen to, defaults to 4000 - `--listen-port <port>` - the port the app should listen to, defaults to 4000
- `--strip-uploads-location <Y|N>` - strip sensitive location data from uploaded images - `--strip-uploads-location <Y|N>` - use ExifTool to strip uploads of sensitive location data
- `--read-uploads-description <Y|N>` - read image descriptions from upload metadata - `--read-uploads-description <Y|N>` - use ExifTool to read image descriptions from uploads
- `--anonymize-uploads <Y|N>` - randomize uploaded filenames - `--anonymize-uploads <Y|N>` - randomize uploaded filenames
- `--dedupe-uploads <Y|N>` - store files based on their hash to reduce data storage requirements if duplicates are uploaded with different filenames - `--dedupe-uploads <Y|N>` - store files based on their hash to reduce data storage requirements if duplicates are uploaded with different filenames
- `--skip-release-env` - skip generation the release environment file - `--skip-release-env` - skip generation the release environment file

View file

@ -56,7 +56,7 @@ Due to aforementioned bug, preferred way of installing frontends in AdminFE is b
![screenshot of admin-fe with instructions on how to install a frontend](../assets/way_to_install_frontends.png) ![screenshot of admin-fe with instructions on how to install a frontend](../assets/way_to_install_frontends.png)
and filling in the fields. Unfortunately AdminFE does not provide the raw data necessary for you to fill those fields, so your best bet is to see what backend returns in browser's devtools or refer to the [source code](https://git.pleroma.social/pleroma/pleroma/-/blob/develop/config/config.exs?ref_type=heads#L742-791). For the most part, only **Name**, **Ref** (i.e. version) and **Build URL** fields are required, although some frontends might also require **Build Directory** to work. and filling in the fields. Unfortunately AdminFE does not provide the raw data necessary for you to fill those fields, so your best bet is to see what backend returns in browser's devtools or refer to the [source code](https://git.pleroma.social/pleroma/pleroma/-/blob/develop/config/config.exs?ref_type=heads#L742-791). For the most part, only **Name**, **Ref** (i.e. version) and **Build URL** fields are required, although some frontends might also require **Build Directory** to work.
Pleroma-FE and Admin-FE builds come from the package registry, not from GitLab job artifacts. For Admin-FE, set **Name** to `admin-fe`, **Ref** to `stable` (or `develop`) and **Build URL** to `https://git.pleroma.social/api/packages/pleroma/generic/admin-fe-builds/${ref}/latest.zip`. Only refs with a published build can be installed: `stable`, `develop`, and release tags once they are published. For pleroma-fe you can use either `master` or `develop` refs, or potentially any ref in GitLab that has artifacts for `build` job, but that's outside scope of this document.
### Selecting default frontend ### Selecting default frontend

View file

@ -177,8 +177,8 @@ To add configuration to your config file, you can copy it from the base config.
* `media_removal`: List of instances to strip media attachments from and the reason for doing so. * `media_removal`: List of instances to strip media attachments from and the reason for doing so.
* `media_nsfw`: List of instances to tag all media as NSFW (sensitive) from and the reason for doing so. * `media_nsfw`: List of instances to tag all media as NSFW (sensitive) from and the reason for doing so.
* `federated_timeline_removal`: List of instances to remove from the Federated Timeline (aka The Whole Known Network) and the reason for doing so. * `federated_timeline_removal`: List of instances to remove from the Federated Timeline (aka The Whole Known Network) and the reason for doing so.
* `reject`: List of instances to reject activities (except deletes) from and the reason for doing so. Activities are also not delivered to these instances, and signed fetches from them are refused in `authorized_fetch_mode`. * `reject`: List of instances to reject activities (except deletes) from and the reason for doing so.
* `accept`: List of instances to only accept activities (except deletes) from and the reason for doing so. If set, activities are also only delivered to these instances, and signed fetches from others are refused in `authorized_fetch_mode`. * `accept`: List of instances to only accept activities (except deletes) from and the reason for doing so.
* `followers_only`: Force posts from the given instances to be visible by followers only and the reason for doing so. * `followers_only`: Force posts from the given instances to be visible by followers only and the reason for doing so.
* `report_removal`: List of instances to reject reports from and the reason for doing so. * `report_removal`: List of instances to reject reports from and the reason for doing so.
* `avatar_removal`: List of instances to strip avatars from and the reason for doing so. * `avatar_removal`: List of instances to strip avatars from and the reason for doing so.
@ -286,9 +286,6 @@ Notes:
* `sign_object_fetches`: Sign object fetches with HTTP signatures * `sign_object_fetches`: Sign object fetches with HTTP signatures
* `authorized_fetch_mode`: Require HTTP signatures for AP fetches * `authorized_fetch_mode`: Require HTTP signatures for AP fetches
* `authorized_fetch_mode_exceptions`: List of IPs (CIDR format accepted) to exempt from HTTP Signatures requirement (for example to allow debugging, you shouldn't otherwise need this) * `authorized_fetch_mode_exceptions`: List of IPs (CIDR format accepted) to exempt from HTTP Signatures requirement (for example to allow debugging, you shouldn't otherwise need this)
* `signature_policy`: What to do with incoming HTTP signatures that do not sign the `date` header (or `(created)`), whose signed date is outside the window below, or that do not sign the `digest` header of a request with a body (or whose body Pleroma did not hash). `:enforce` (default) treats them as invalid, `:log` only logs a warning.
* `signature_max_age`: How old, in seconds, the signed date of an incoming HTTP signature can be. Default: `7200` (2 hours).
* `signature_max_clock_skew`: How far, in seconds, the signed `date` of an incoming HTTP signature can be in the future. Default: `3600` (1 hour). A `(created)` time in the future is always rejected.
## Pleroma.User ## Pleroma.User
@ -544,15 +541,6 @@ Available caches:
## HTTP client ## HTTP client
Pleroma uses [Gun](https://github.com/ninenines/gun) for outgoing HTTP requests. To use Hackney instead:
```elixir
config :tesla, adapter: Tesla.Adapter.Hackney
```
!!! note
With Hackney, size limits for fetched responses (for example for link previews) are checked only after Hackney has read the whole response. They limit what Pleroma keeps, not how much it downloads or holds in memory. Gun stops reading at the limit.
### :http ### :http
* `proxy_url`: an upstream proxy to fetch posts and/or media with, (default: `nil`) * `proxy_url`: an upstream proxy to fetch posts and/or media with, (default: `nil`)
@ -562,8 +550,6 @@ config :tesla, adapter: Tesla.Adapter.Hackney
### :hackney_pools ### :hackney_pools
*For `hackney` adapter*
Advanced. Tweaks Hackney (http client) connections pools. Advanced. Tweaks Hackney (http client) connections pools.
There's three pools used: There's three pools used:
@ -587,8 +573,7 @@ Settings for HTTP connection pool.
* `:connection_acquisition_wait` - Timeout to acquire a connection from pool.The total max time is this value multiplied by the number of retries. * `:connection_acquisition_wait` - Timeout to acquire a connection from pool.The total max time is this value multiplied by the number of retries.
* `connection_acquisition_retries` - Number of attempts to acquire the connection from the pool if it is overloaded. Each attempt is timed `:connection_acquisition_wait` apart. * `connection_acquisition_retries` - Number of attempts to acquire the connection from the pool if it is overloaded. Each attempt is timed `:connection_acquisition_wait` apart.
* `:max_connections` - Maximum total number of connections in the pool. HTTP/1 origins may use multiple connections within this limit, while HTTP/2 connections are multiplexed. * `:max_connections` - Maximum number of connections in the pool.
* `:max_idle_time` - Time before an unused connection is closed.
* `:connect_timeout` - Timeout to connect to the host. * `:connect_timeout` - Timeout to connect to the host.
* `:reclaim_multiplier` - Multiplied by `:max_connections` this will be the maximum number of idle connections that will be reclaimed in case the pool is overloaded. * `:reclaim_multiplier` - Multiplied by `:max_connections` this will be the maximum number of idle connections that will be reclaimed in case the pool is overloaded.
@ -705,19 +690,15 @@ This filter replaces the filename (not the path) of an upload. For complete obfu
No specific configuration. No specific configuration.
#### Pleroma.Upload.Filter.Exif.StripLocation #### Pleroma.Upload.Filter.Exiftool.StripLocation
This filter strips GPS and location metadata from JPEG, WebP, HEIC, AVIF and TIFF images, leaving color profiles and attributes intact. For PNG images it removes all text and EXIF metadata chunks. Images are not re-encoded, and other formats are left unchanged. This filter only strips the GPS and location metadata with Exiftool leaving color profiles and attributes intact.
It replaces the deprecated `Pleroma.Upload.Filter.Exiftool.StripLocation`, which no longer needs exiftool.
No specific configuration. No specific configuration.
#### Pleroma.Upload.Filter.Exif.ReadDescription #### Pleroma.Upload.Filter.Exiftool.ReadDescription
This filter reads the ImageDescription and iptc:Caption-Abstract fields so clients can prefill the media description field. This filter reads the ImageDescription and iptc:Caption-Abstract fields with Exiftool so clients can prefill the media description field.
It replaces the deprecated `Pleroma.Upload.Filter.Exiftool.ReadDescription`, which no longer needs exiftool.
No specific configuration. No specific configuration.
@ -877,23 +858,21 @@ Web Push Notifications configuration. You can use the mix task `mix web_push.gen
* ``private_key``: VAPID private key * ``private_key``: VAPID private key
## :logger ## :logger
* Logging to console/stdout is done by default, use `{ExSyslogger, :ex_syslogger}` to log to syslog * `backends`: `:console` is used to send logs to stdout, `{ExSyslogger, :ex_syslogger}` to log to syslog
An example to enable ONLY ExSyslogger (f/ex in ``prod.secret.exs``) with info and debug suppressed: An example to enable ONLY ExSyslogger (f/ex in ``prod.secret.exs``) with info and debug suppressed:
```elixir ```elixir
config :pleroma, :logger, config :logger,
backends: [{ExSyslogger, :ex_syslogger}] backends: [{ExSyslogger, :ex_syslogger}]
config :logger, default_handler: false
config :logger, :ex_syslogger, config :logger, :ex_syslogger,
level: :warning level: :warning
``` ```
Another example, keeping console output and adding the pid to syslog output: Another example, keeping console output and adding the pid to syslog output:
```elixir ```elixir
config :pleroma, :logger, config :logger,
backends: [{ExSyslogger, :ex_syslogger}] backends: [:console, {ExSyslogger, :ex_syslogger}]
config :logger, :ex_syslogger, config :logger, :ex_syslogger,
level: :warning, level: :warning,
@ -904,22 +883,23 @@ See: [logger’s documentation](https://hexdocs.pm/logger/Logger.html) and [ex_s
An example of logging info to local syslog, but debug to console: An example of logging info to local syslog, but debug to console:
```elixir ```elixir
config :pleroma, :logger, config :logger,
backends: [{ExSyslogger, :ex_syslogger}] backends: [ {ExSyslogger, :ex_syslogger}, :console ],
level: :info
config :logger, :ex_syslogger, config :logger, :ex_syslogger,
level: :info, level: :info,
ident: "pleroma", ident: "pleroma",
format: "$metadata[$level] $message" format: "$metadata[$level] $message"
config :logger, :default_handler, config :logger, :console,
level: :debug level: :debug,
config :logger, :default_formatter,
format: "\n$time $metadata[$level] $message\n", format: "\n$time $metadata[$level] $message\n",
metadata: [:request_id] metadata: [:request_id]
``` ```
## Database options ## Database options
### RUM indexing for full text search ### RUM indexing for full text search
@ -1152,9 +1132,8 @@ Boolean, enables/disables in-database configuration. Read [Transferring the conf
List of valid configuration sections which are allowed to be configured from the List of valid configuration sections which are allowed to be configured from the
database. Settings stored in the database before the whitelist is configured are database. Settings stored in the database before the whitelist is configured are
still applied. Consider running the `mix pleroma.config filter_whitelisted` task still applied, so it is suggested to only use the whitelist on instances that
after updating the whitelist. Read [Remove non-whitelisted configs from the database](../administration/CLI_tasks/config.md#remove-non-whitelisted-configs-from-the-database) have not migrated the config to the database.
for more information.
Example: Example:
```elixir ```elixir
@ -1203,20 +1182,6 @@ Control favicons for instances.
* `enabled`: Allow/disallow displaying and getting instances favicons * `enabled`: Allow/disallow displaying and getting instances favicons
## :retention
Bounded retention of remote content. Local posts are your data; remote posts are a cache of somebody else's, and this treats them that way. When enabled, a cron worker (`Pleroma.Workers.Cron.RetentionWorker`, hourly by default) evicts a batch of remote threads that nobody local has interacted with and that have been quiet for longer than `remote_post_retention_days` (see [`:instance`](#instance)). The database then plateaus instead of growing without limit.
A thread is never evicted if it contains a local post, reply, favourite, repeat or reaction, a post bookmarked by a local user, a post addressed to a local user (direct messages and mentions), a post quoted by a local post, a post a local user still has a notification for, or a post that was reported. Relationship activities (follows, blocks) and chat messages are never touched. Evicted posts are refetched on demand when somebody opens them again, as with `prune_objects`.
* `enabled`: Run the worker. Defaults to `false`.
* `max_objects`: Optional watermark. When the `objects` table is estimated to hold more rows than this, the oldest unpinned remote threads that have been quiet for more than a day are evicted, whatever `remote_post_retention_days` says. Defaults to `nil` (age only).
* `batch_size`: Number of activities walked per run. Their threads are checked and, if unpinned, evicted. Defaults to `50000`.
* `keep_non_public`: Also keep threads that contain a non-public post. Defaults to `false`.
!!! note
The worker walks the `activities` table in id order, `batch_size` activities per run, up to the id that corresponds to the retention deadline, and remembers its position in the `retention_cursors` table. Each activity is visited once, when it becomes old enough, and only the threads it belongs to are checked through the context index. Over the `max_objects` watermark a second walk with its own cursor runs up to one day ago instead. The first run starts from the oldest activity; on an instance that never pruned this backlog takes many runs, so run `prune_objects --keep-threads --prune-orphaned-activities` once for the initial cut. Threads that were kept and later lost their pin (removed bookmarks, cleared notifications of other kinds) are only revisited on a fresh walk: delete the row from `retention_cursors` to restart from the beginning. Space freed by eviction is reused by new rows; it is not handed back to the filesystem unless you `VACUUM FULL`.
## Pleroma.User.Backup ## Pleroma.User.Backup
!!! note !!! note

View file

@ -10,6 +10,3 @@ The other way to do it, for example, with Tor you would most likely add somethin
``` ```
config :pleroma, :http, proxy_url: {:socks5, :localhost, 9050} config :pleroma, :http, proxy_url: {:socks5, :localhost, 9050}
``` ```
The Gun HTTP adapter supports SOCKS5. SOCKS4 proxies require another HTTP adapter.
For regular HTTP proxies, Gun forwards plain HTTP requests directly and uses CONNECT tunnels for HTTPS requests.

View file

@ -10,14 +10,6 @@ To use built-in search that has no external dependencies, set the search module
While it has no external dependencies, it has problems with performance and relevancy. While it has no external dependencies, it has problems with performance and relevancy.
With a GIN index (the default), search queries limit how many matches PostgreSQL considers (`gin_fuzzy_search_limit`, see [PostgreSQL's docs](https://www.postgresql.org/docs/current/gin.html#GIN-TIPS)). This keeps searches for common words fast on large databases, but the results are incomplete and can change between requests. On smaller instances you can turn it off for exact results:
> config :pleroma, Pleroma.Search.DatabaseSearch, gin_fuzzy_search_limit: nil
Without a limit, searches for common words can take longer than the database timeout on large databases, and then return nothing.
Earlier versions of Pleroma set this limit for every database connection, which also made other GIN index scans (for example recipient lookups) incomplete. It is now only set for search queries.
## QdrantSearch ## QdrantSearch
This uses the vector search engine [Qdrant](https://qdrant.tech) to search the posts in a vector space. This needs a way to generate embeddings and uses the [OpenAI API](https://platform.openai.com/docs/guides/embeddings/what-are-embeddings). This is implemented by several project besides OpenAI itself, including the python-based fastembed-server found in `supplemental/search/fastembed-api`. This uses the vector search engine [Qdrant](https://qdrant.tech) to search the posts in a vector space. This needs a way to generate embeddings and uses the [OpenAI API](https://platform.openai.com/docs/guides/embeddings/what-are-embeddings). This is implemented by several project besides OpenAI itself, including the python-based fastembed-server found in `supplemental/search/fastembed-api`.
@ -93,7 +85,7 @@ You will see a "Default Admin API Key", this is the key you actually put into yo
### Initial indexing ### Initial indexing
After setting up the configuration, you'll want to index all of your already existing posts. Only public/unlisted posts are indexed. You'll only After setting up the configuration, you'll want to index all of your already existing posts. Only public posts are indexed. You'll only
have to do it one time, but it might take a while, depending on the amount of posts your instance has seen. This is also a fairly RAM have to do it one time, but it might take a while, depending on the amount of posts your instance has seen. This is also a fairly RAM
consuming process for `meilisearch`, and it will take a lot of RAM when running if you have a lot of posts (seems to be around 5G for ~1.2 consuming process for `meilisearch`, and it will take a lot of RAM when running if you have a lot of posts (seems to be around 5G for ~1.2
million posts while idle and up to 7G while indexing initially, but your experience may be different). million posts while idle and up to 7G while indexing initially, but your experience may be different).
@ -153,155 +145,3 @@ This will clear **all** the posts from the search index. Note, that deleted post
there is no need to actually clear the whole index, unless you want **all** of it gone. That said, the index does not hold any information there is no need to actually clear the whole index, unless you want **all** of it gone. That said, the index does not hold any information
that cannot be re-created from the database, it should also generally be a lot smaller than the size of your database. Still, the size that cannot be re-created from the database, it should also generally be a lot smaller than the size of your database. Still, the size
depends on the amount of text in posts. depends on the amount of text in posts.
## ParadeDB
[ParadeDB](https://www.paradedb.com/) is a Postgres extension that provides BM25 full-text search. In Pleroma, it can be used as an
external search backend by pointing Pleroma at a separate Postgres instance with the `pg_search` extension installed.
Pleroma's integration suite tests `pg_search` 0.24.3 on PostgreSQL 15.
Pleroma will maintain a small `pleroma_search_documents` table in that database (via the existing search indexing queue) and run search
queries against it.
The indexed text includes status content, content warnings, and attachment descriptions.
### Configuration
Set the search module to `Pleroma.Search.ParadeDB` and configure the ParadeDB database URL. These settings must be in static/runtime config
(or `PARADEDB_DATABASE_URL`) so the dedicated ParadeDB Repo is started with the application. They cannot be migrated to or changed through
ConfigDB.
> config :pleroma, Pleroma.Search, module: Pleroma.Search.ParadeDB
>
> config :pleroma, Pleroma.Search.ParadeDB,
> url: System.get_env("PARADEDB_DATABASE_URL"),
> table: "pleroma_search_documents",
> fuzzy_distance: 0
>
> config :pleroma, Pleroma.Search.ParadeDB.Repo,
> pool_size: 2,
> prepare: :unnamed
When connecting over an untrusted network, enable certificate verification in the Repo configuration. For example:
> config :pleroma, Pleroma.Search.ParadeDB.Repo,
> ssl: [
> verify: :verify_peer,
> cacertfile: "/etc/pleroma/paradedb-ca.pem",
> server_name_indication: ~c"paradedb.example.com"
> ]
### Initial rollout
The `pg_search` extension must already be available in the database. Creating the extension normally requires an administrative database
role. The Pleroma runtime role requires `CONNECT` on the database, `USAGE` on the table's schema and the `pdb` schema, and `SELECT`, `INSERT`, `UPDATE`,
and `DELETE` on the generated table. For example, after creating the table as its owner:
```sql
GRANT CONNECT ON DATABASE paradedb TO pleroma_search;
GRANT USAGE ON SCHEMA public, pdb TO pleroma_search;
GRANT SELECT, INSERT, UPDATE, DELETE ON TABLE pleroma_search_documents TO pleroma_search;
```
Use this rollout order to prevent jobs from being handled by the previous backend:
1. Install `pg_search` 0.24.3 on PostgreSQL 15 or another deliberately tested combination.
2. Stop Pleroma so no search indexing jobs are running.
3. Put the ParadeDB backend in static configuration.
4. Create the table and BM25 index in a one-shot offline process using `PARADEDB_DATABASE_URL` with the table owner/setup credential.
5. Apply the runtime grants shown above, set the service's `PARADEDB_DATABASE_URL` to the restricted runtime credential, and start Pleroma.
6. Start the initial backfill and monitor the `search_indexing` queue.
Create the table and BM25 index once with:
=== "OTP"
```sh
PARADEDB_DATABASE_URL='OWNER_URL' PLEROMA_CTL_RPC_DISABLED=true \
./bin/pleroma_ctl search.indexer create_index
```
=== "From Source"
```sh
PARADEDB_DATABASE_URL='OWNER_URL' mix pleroma.search.indexer create_index
```
The task currently prints an error without returning a failing process status. Verify that it prints `Index created` before continuing.
### Backfill
Run an initial indexing pass to enqueue existing posts:
=== "OTP"
```sh
./bin/pleroma_ctl search.indexer index
```
=== "From Source"
```sh
PARADEDB_DATABASE_URL='RUNTIME_URL' mix pleroma.search.indexer index
```
The command enqueues up to 100,000 Create activities by default. It uses keyset pagination, so new activities arriving during the backfill
do not shift the remaining pages. The defaults and accepted options are:
* `--limit`: maximum activities to enqueue in this run; defaults to `100000` and must be positive
* `--step`: activities fetched from Pleroma's database per page; defaults to `1000` and must be positive
* `--chunk`: jobs inserted into Oban per batch; defaults to `100` and must be positive
* `--before`: resume before the checkpoint activity ID printed by an earlier run; the cursor is exclusive
The checkpoint is the last activity enqueued, not confirmation that its job succeeded. Repeat the command with its last `--before`
checkpoint only when it reports that more activities remain. Inspect failed or discarded Oban jobs as well as waiting jobs before declaring
the backfill complete.
The same operation can be run from an attached console while Pleroma is online:
```elixir
Pleroma.Search.Backfill.run(limit: 10_000)
```
The returned `next_cursor` can be supplied as `before` when `exhausted` is `false`. The attached API also accepts `limit: :infinity`, but this
can create an unbounded number of Oban rows; bounded runs are safer on large instances. An `on_page` callback may be supplied for progress
reporting.
Note: Like the other external search backends, only public/unlisted Notes are indexed.
Set `fuzzy_distance` to `1` or `2` to allow typo-tolerant matching (`2` is the maximum ParadeDB supports).
Indexing runs via the Oban `search_indexing` queue. Its stock configuration starts paused so the search health monitor can control it; verify
that the queue is running before backfilling. A manually managed queue can be enabled with `search_indexing: 10` in the Oban `queues`
configuration instead of a `paused: true` entry.
Monitor that queue until the backfill jobs have drained before evaluating search completeness.
### Rebuilding
Stop Pleroma, or otherwise ensure no search indexing jobs are running, before rebuilding. While ParadeDB is still the configured backend,
run `drop_index`, then `create_index` with the table owner/setup credential. Reapply runtime grants after recreating the table, restart
Pleroma, and begin a new backfill. The DDL tasks print failures without returning a failing process status, so verify the exact `Index
dropped` and `Index created` success messages. Dropping the table removes only derived search data; Pleroma activities remain in the primary
database.
### Rolling back
To retain the ParadeDB table for a later retry, configure `Pleroma.Search.DatabaseSearch` (or the previous external backend) in static config
and restart Pleroma.
Before switching backends, inspect the `search_indexing` queue. Drain or cancel pending backfill jobs, or explicitly accept that they will run
against the newly configured backend after restart.
To remove the table during rollback, first stop Pleroma and run `drop_index` with the table owner/setup credential while ParadeDB is still
configured:
=== "OTP"
```sh
PARADEDB_DATABASE_URL='OWNER_URL' PLEROMA_CTL_RPC_DISABLED=true \
./bin/pleroma_ctl search.indexer drop_index
```
=== "From Source"
```sh
PARADEDB_DATABASE_URL='OWNER_URL' mix pleroma.search.indexer drop_index
```
Verify that the task prints `Index dropped`. Then change the backend in static config and restart. The ParadeDB environment variable may be
removed after removing the ParadeDB stanza or switching to a backend that does not start its Repo. After switching away from ParadeDB, the
generic `drop_index` task targets the newly configured backend and will not remove the ParadeDB table; remove it directly with the database
owner instead.

Some files were not shown because too many files have changed in this diff Show more