Commit graph

4710 commits

Author SHA1 Message Date
201fa97769 Move code to generate apub urls into lemmy_api_common 2022-12-02 10:46:49 +01:00
904d7bec2f Builds lemmy_routes in parallel with lemmy_apub 2022-12-02 10:46:49 +01:00
030afbc2e7 Merge websocket crate into api_common 2022-12-02 10:46:49 +01:00
70e3feb174
Check user accepted before sending jwt in password reset (fixes #2591) (#2597)
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-12-01 16:36:03 -05:00
ccb6435c1d
Relax honeypot check (fixes #2595) (#2596)
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-12-01 16:33:59 -05:00
bcf5c91f81
Use audience field to federate items in groups (fixes #2464) (#2584) 2022-12-01 15:52:49 -05:00
41d4852efc
Federate group moderators using attributedTo field (#2588)
* Federate group moderators using attributedTo field

* fix tests

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-11-25 09:01:58 -05:00
96a2bec691
Set cargo home in ci to avoid redownloading deps between steps (#2587)
* Set cargo home in ci to avoid redownloading deps between steps

* remove protobuf

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-11-24 23:43:31 -05:00
d39bc14c43
Add some more clippy lints (#2586)
* Add some more clippy lints

* restore config

* no allow dirty

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-11-24 16:38:00 +00:00
c3c4508a72
Use release docker image for nightly build (#2583)
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-11-24 08:33:58 -05:00
d20d2b9218
Implement federated user following (fixes #752) (#2577)
* Implement federated user following (fixes #752)

* rewrite send_activity_in_community and add docs, remove default for column pending

* improve migration

* replace null values in db migration
2022-11-23 18:40:47 -05:00
4ddca46228 Revert "Test drone (#2582)"
This reverts commit 87c7ee5490.
2022-11-23 21:25:24 +01:00
87c7ee5490
Test drone (#2582) 2022-11-23 15:23:23 -05:00
bb1e3bc891
Upgrade activitypub_federation to 0.3.4 (#2581) 2022-11-23 09:06:25 -05:00
bc19d94e3c
Upgrade activitypub_federation crate to 0.3.3 (ref #2511) (#2578) 2022-11-22 07:20:31 -05:00
872c60a013
Remove federation settings, rely on sensible defaults instead (#2574)
This affects federation_strict_allowlist and federation_http_fetch_retry_limit
2022-11-21 11:44:34 -05:00
Dessalines
65041a20bb
Fix clippy lints. (#2572)
* Fix clippy lints.

* Fix fmt.

* Dont use cargo-workspaces for fix-clippy script.
2022-11-21 10:21:09 +00:00
Anon
c27d2a5687
Add support for Taglines (#2548)
* Add support for Taglines

* recreate migration

* Update content column -> Text

* Optimize replace function

* Change taglines to Option

* Move Ok() call

* Move taglines to GetSiteResponse

* Fix logic

Co-authored-by: layla <layla@chapo.dev>
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-11-19 09:48:29 -05:00
6f3bf4634b
Various pedantic clippy fixes (#2568)
* Various pedantic clippy fixes

* more clippy pedantic fixes

* try to fix ci

* add fix clippy script, use rust 1.65

* fix clippy
2022-11-19 04:33:54 +00:00
a39cf31466
Sort vecs before assert to avoid random test failures (#2569)
* Sort language read queries to avoid random test failures

* change sort columns
2022-11-18 20:30:59 -05:00
23d0f3ed3c
Display build status badge from drone.join-lemmy.org (#2564)
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-11-17 18:51:17 +00:00
df7809fbbb
Specify dependencies and metadata for entire workspace (#2565)
* Specify dependencies and metadata for entire workspace (fixes #2474)

* building api_common shouldnt depend on diesel

* remove drone task

* try with quotes

* fix clippy

* more clippy
2022-11-17 15:23:01 +00:00
63c237d6df
Use enum_delegate crate (#2554) 2022-11-16 22:51:05 +00:00
24756af84b
Live reload settings (fixes #2508) (#2543)
* Live reload rate limit settings (fixes #2508)

* fix tests
2022-11-16 14:06:22 -05:00
b16df59373
Fix activity list test (#2562) 2022-11-15 22:38:26 +00:00
0b86ffbdbd Remove unwrap 2022-11-14 15:30:44 +01:00
a0fed24cee
When announcing incoming activities, keep extra fields (#2550) 2022-11-12 08:52:57 -05:00
e3bb43542c
Mobilizon federation (#2544)
* Mobilizon federation

* Also accept document attachments from mobilizon
2022-11-12 08:51:08 -05:00
83d2959b4b
Update doku dependency for easier formatting of defaults.hjson (#2553) 2022-11-11 16:01:29 -05:00
ᡥᠠᡳᡤᡳᠶᠠ ᡥᠠᠯᠠ·ᠨᡝᡴᠣ 猫
42674b7abd
Translated README.md to Chinese (#2549)
* Add Mandarin locales

`README.zh.hans.md` for Simplified Chinese, `README.zh.hant.md` for Traditional Chinese

* Fix relative links to README
2022-11-11 10:10:13 +00:00
Dessalines
5d837780f5
Add diesel_async, get rid of blocking function (#2510)
* Moving settings to Database.

- Moves many settings into the database. Fixes #2285
- Adds a local_site and instance table. Fixes #2365 . Fixes #2368
- Separates SQL update an insert forms, to avoid runtime errors.
- Adds TypedBuilder to all the SQL forms, instead of default.

* Fix weird clippy issue.

* Removing extra lines.

* Some fixes from suggestions.

* Fixing apub tests.

* Using instance creation helper function.

* Move forms to their own line.

* Trying to fix local_site_data, still broken.

* Testing out async

* Testing out async 2

* Fixing federation tests.

* Trying to fix check features 1.

* Starting on adding diesel async. 1/4th done.

* Added async to views and schema.

* Adding some more async

* Compiling now.

* Added diesel async. Fixes #2465

* Running clippy --fix

* Trying to fix cargo test on drone.

* Trying new muslrust.

* Trying a custom dns

* Trying a custom dns 2

* Trying a custom dns 3

* Trying a custom dns 4

* Trying a custom dns 5

* Trying a custom dns 6

* Trying a custom dns 7

* Addressing PR comments.

* Adding check_apub to all verify functions.

* Reverting back drone.

* Fixing merge

* Fix docker images.

* Adding missing discussion_languages.

* Trying to fix federation tests.

* Fix site setup user creation.

* Fix clippy

* Fix clippy 2

* Test api faster

* Try to fix 1

* Try to fix 2

* What are these lines about

* Trying to fix 3

* Moving federation test back to top.

* Remove logging cat.
2022-11-09 10:05:00 +00:00
ceae0f5993
Use urlencoding for db url params (fixes #2532) (#2537) 2022-11-07 21:29:32 -05:00
a0a84d91ce
Dont serve apub json for removed objects (ref #2522) (#2538) 2022-11-04 20:57:28 -04:00
50a2233b52
Fix password length check (#2536) 2022-11-04 20:56:38 -04:00
2207fed0f5
Remove explicit panic from db connection code (fixes #2533) (#2535) 2022-11-04 20:53:46 -04:00
9393195827
Send error message when rate limit is reached (#2527)
* Send error message when rate limit is reached

* l18n key
2022-11-03 18:13:40 +00:00
5e871ca7ba
Mark own private messages as read in api (fixes #2484) (#2531) 2022-11-03 13:41:44 -04:00
b5cd732372
Mark objects as not deleted when received via apub (fixes #2507) (#2528) 2022-11-03 09:39:30 -04:00
Dessalines
cb753b045f
Group imports dess (#2526)
* Group imports with rustfmt

* Running cargo fmt again.

Co-authored-by: Felix Ableitner <me@nutomic.com>
2022-11-02 15:18:22 -04:00
28eade6168
Fix invalid config in docker/prod (fixes #2520) (#2524) 2022-11-02 18:50:09 +00:00
Dessalines
ed9e91345a
Fix local site images. (#2519)
* Fix local site images.

* It should be set up.
2022-11-02 12:10:40 +00:00
sam365724
7aa6d6b3e1
Fix 2455: Check auth for pictrs when instance is private. (#2477)
* Fix 2455: Check auth for pictrs when instance is private.

* Update, no utils function, use of existing get_local_user_view_from_jwt

* rustup toolchain install nightly (ftw)
2022-10-28 10:43:33 -04:00
6aa9bdebae
Fix limit_languages to operate on correct instance (fixes #2496) (#2518)
* Fix limit_languages to operate on correct instance (fixes #2496)

* cargo fmt
2022-10-28 10:42:05 -04:00
3b0be52e67
Image improvements (#2513)
* Image improvements

* remove rate limits
2022-10-28 14:34:40 +00:00
b0c3185663
Make verify apub url function async (#2514)
* Make verify apub url function async

* cleanup

* use dep from crates.io

* dont use unwrap
2022-10-28 09:38:22 -04:00
Dessalines
235cc8b228
Moving settings to Database. (#2492)
* Moving settings to Database.

- Moves many settings into the database. Fixes #2285
- Adds a local_site and instance table. Fixes #2365 . Fixes #2368
- Separates SQL update an insert forms, to avoid runtime errors.
- Adds TypedBuilder to all the SQL forms, instead of default.

* Fix weird clippy issue.

* Removing extra lines.

* Some fixes from suggestions.

* Fixing apub tests.

* Using instance creation helper function.

* Move forms to their own line.

* Trying to fix local_site_data, still broken.

* Fixing federation tests.

* Trying to fix check features 1.

* Addressing PR comments.

* Adding check_apub to all verify functions.
2022-10-27 09:24:07 +00:00
276a8c2bd3
Enable lto, strip symbols via cargo.toml (#2512) 2022-10-25 15:10:07 +00:00
Dessalines
9ac13a0891
Fix docker dev build (#2509)
* Fixing docker dev build.

* Remove volume mount files.

* Fixing pictrs.

* Addressing PR comments.
2022-10-21 15:13:24 +00:00
aaaea2006c
Federate votes as private (#2501) 2022-10-18 03:13:18 +00:00
74bc1198ce
Dont try to send activities if federation is disabled (fixes #2499) (#2500) 2022-10-17 14:29:18 -04:00