Commit graph

178 commits

Author SHA1 Message Date
dc327652a5
Add db table for login tokens which allows for invalidation (#3818)
* wip

* stuff

* fmt

* fmt 2

* fmt 3

* fix default feature

* use Authorization header

* store ip and user agent for each login

* add list_logins endpoint

* serde(skip) for token

* fix api tests

* A few suggestions for login_token (#3991)

* A few suggestions.

* Fixing SQL format.

* review

* review

* rename cookie

---------

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-10-09 12:46:12 +02:00
a5b8583aab Version 0.19.0-beta.7 2023-10-05 16:01:12 -04:00
9275041f42 Version 0.19.0-rc.1 2023-09-26 23:01:19 -04:00
SleeplessOne1917
13b20b0502 Address PR feedback 2023-09-25 06:37:45 -04:00
SleeplessOne1917
ed8dae99f1 Merge branch 'main' into bearer-token 2023-09-24 17:47:17 -04:00
SleeplessOne1917
519e800b33 feat: Replace ad hoc auth header with internet standard bearer token
auth header
2023-09-22 21:26:27 -04:00
Dessalines
b16661a17d
Merge branch 'main' into comment-fix 2023-09-21 11:20:49 -04:00
f858d8cbce
Remove explicit auth params (#3946)
* Remove explicit auth params (ref #3725)

Only take auth via header or cookie. This requires a new version
of lemmy-js-client for api tests to pass.

* rework api_crud

* remove remaining auth params, move logic to session middleware

* fmt, fix test

* update js client

* remove auth param from api tests

* Pass auth as header

* add !

* url vars, setHeader

* cleanup

* fmt

* update

* Updating for new lemmy-js-client.

---------

Co-authored-by: Dessalines <tyhou13@gmx.com>
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-09-21 06:42:28 -04:00
SleeplessOne1917
553c5bda88 Update versions to correct version 2023-09-18 22:07:31 -04:00
phiresky
375d9a2a3c
Persistent, performant, reliable federation queue (#3605)
* persistent activity queue

* fixes

* fixes

* make federation workers function callable from outside

* log federation instances

* dead instance detection not needed here

* taplo fmt

* split federate bin/lib

* minor fix

* better logging

* log

* create struct to hold cancellable task for readability

* use boxfuture for readability

* reset submodule

* fix

* fix lint

* swap

* remove json column, use separate array columns instead

* some review comments

* make worker a struct for readability

* minor readability

* add local filter to community follower view

* remove separate lemmy_federate entry point

* fix remaining duration

* address review comments mostly

* fix lint

* upgrade actitypub-fed to simpler interface

* fix sql format

* increase delays a bit

* fixes after merge

* remove selectable

* fix instance selectable

* add comment

* start federation based on latest id at the time

* rename federate process args

* dead instances in one query

* filter follow+report activities by local

* remove synchronous federation

remove activity sender queue

* lint

* fix federation tests by waiting for results to change

* fix fed test

* fix comment report

* wait some more

* Apply suggestions from code review

Co-authored-by: SorteKanin <sortekanin@gmail.com>

* fix most remaining tests

* wait until private messages

* fix community tests

* fix community tests

* move arg parse

* use instance_id instead of domain in federation_queue_state table

---------

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
Co-authored-by: SorteKanin <sortekanin@gmail.com>
2023-09-09 12:25:03 -04:00
SorteKanin
722027ce2e
Bump ts_rs version (#3947)
Co-authored-by: Nutomic <me@nutomic.com>
2023-09-06 13:04:24 -04:00
fed6542055
Implement remote follow (#3738)
* Add remote follow url to webfinger response

* update apub lib
2023-08-31 09:00:41 -04:00
phiresky
514f2222e0
Fix time zone handling (#3496)
* convert naive time to utc time

* compounding fixes

* cargo fmt

* fix the rest

* fix down migration

* fix migrations

* fix after merge

* clippy fix

* ap-fed 0.5.0

---------

Co-authored-by: Nutomic <me@nutomic.com>
2023-08-24 11:27:00 -04:00
91c024fd98 Revert "Version 0.18.4-rc.2"
This reverts commit 48466b6826.
2023-08-07 17:12:09 +02:00
48466b6826 Version 0.18.4-rc.2 2023-08-07 17:09:10 +02:00
2d0f77af59
Dont use sha hash for password reset token (fixes #3491) (#3795) 2023-08-02 13:02:53 -04:00
dullbananas
9b123f45ec
Enable gzip for reqwest (#3696)
This will reduce bandwidth used by federation

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-07-26 12:22:14 +02:00
3753a3bf54
Upgrade activitypub library to 0.4.6 (fixes #3222) (#3675) 2023-07-20 11:33:19 -04:00
Dessalines
164f4b93d9
Make lemmy_api_common wasm-compatible (#3587)
* Fixing lemmy_api_common optionals

* Adding taplo for .toml files.

* Versioning taplo in woodpecker.

* Addressing PR comments.
2023-07-14 10:45:18 +02:00
39f28c1a40
Add dev profile to strip symbols and disable debug info (ref #3610) (#3611)
* Add dev profile to strip symbols and disable debug info (ref #3610)

This significantly speeds up builds:
- with strip symbols and debug 0: 43s
- without: 169s

* add comment, no strip symbols
2023-07-13 14:50:17 -04:00
ff26bc21af
Upgrade all dependencies (#3526)
* Upgrade all dependencies

* as base64
2023-07-10 15:00:55 +02:00
0c82f4e660 Version 0.18.1 2023-07-07 09:24:49 -04:00
22cdcc6b60 Version 0.18.1-rc.10 2023-07-06 14:46:46 +02:00
Andrew Fields
1e99e8b9dc
Add Prometheus endpoint (#3456)
Add a server for serving Prometheus metrics. Include a configuration
block in the config file. Provide HTTP metrics on the API, along with
process-level metrics and DB pool metrics.
2023-07-05 13:25:19 +02:00
Lemmus.org
ff47d97bd3
Add feature for enabling json logging (#3462) 2023-07-04 07:11:47 -04:00
7a04971ecd Version 0.18.1-rc.9 2023-07-03 17:16:48 -04:00
phiresky
cb28af508d
don't strip, log trace if requested (#3425) 2023-06-30 09:32:43 -04:00
3159eedd99 Version 0.18.1-rc.4 2023-06-29 10:45:59 -04:00
Dessalines
6c64cb5233
Fixing release script. (#3398)
* Fixing release script.

* Version 0.18.1-rc.2

* Removing cargo update from release script.

* Fixing topdir location.
2023-06-29 16:17:59 +02:00
ad6f244b61 Version 0.18.1-rc.1 2023-06-27 08:14:46 -04:00
Sander Saarend
211e76dc27
Batch hot rank updates (#3175) 2023-06-27 10:13:51 +02:00
dullbananas
b2a9d4a335
Use compression middleware (#3343) 2023-06-26 12:54:41 +02:00
a39e948b52 Remove unused actix_rt dependency 2023-06-26 12:14:47 +02:00
Sander Saarend
6d67f88603
Add support for sslmode=require for diesel-async DB connections (#3189) 2023-06-26 10:25:38 +02:00
cetra3
d7da911a48
Remove actix_rt & use standard tokio spawn (#3158)
* Remove `actix_rt` & use standard tokio spawn

* Adjust rust log back down

* Format correctly

* Update cargo lock

* Add DB settings

* Change name and update to latest rev

* Clean up formatting changes

* Move `worker_count` and `worker_retry_count` to settings

* Update defaults

* Use `0.4.4` instead of git branch
2023-06-26 10:24:11 +02:00
63d3759c48 Version 0.18.0 2023-06-23 08:41:20 -04:00
cb3b9b1a66 Version 0.18.0-rc.8 2023-06-23 07:07:51 -04:00
60baebcb14 Version 0.18.0-rc.6 2023-06-22 08:55:08 -04:00
ffce66abb8
Update apub library to 0.4.4 (#3258)
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-06-22 08:35:12 -04:00
289052f261 Version 0.18.0-rc.5 2023-06-21 16:02:42 -04:00
3775418952 Version 0.18.0-rc.4 2023-06-21 08:05:15 -04:00
b5dba17426
Update all dependencies (#3091) 2023-06-15 11:37:05 +02:00
25275b79ee
Upgrade activitypub-federation to 0.4.1 (#3039)
This improves logging so that its not necessary to enable debug
logs to find out that activity worker count needs to be increased.
2023-06-12 14:12:15 -04:00
Charles Hall
f50325e78a
update doku (#3003)
Fixes malformed documentation generated by previous version.
2023-06-12 05:55:47 -04:00
Carlrs
24323e17b2
update diesel to 2.1.0 and diesel-async to 0.3.0 (issue #2882) (#2895)
* update diesel to 2.1.0 and diesel-async to 0.3.0 (issue #2882)

* get rid of deprecated RawValue type alias usage, explicitly import diesel types instead of using wildcard import

* Update diesel-derive-enum and diesel-derive-newtype libraries

* Revert manual changes to schema.rs

* Update to newer diesel-cli image in CI, run fix-clippy before schema comparison, update schema to one generated with diesel-cli 2.1.0 and clippyfixed

* Remove wildcard import lint, fix diesel schema pipeline

---------

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-06-07 12:54:40 +02:00
3565ad984a
Remove chatserver (#2919)
* Remove chatserver

* fix clippy

* Remove captchas (fixes #2922)

* fix prettier

* fix api_common build

* cargo fmt
2023-06-06 12:27:22 -04:00
Dessalines
af3eb6e27b
Add CORS support for debug mode. (#2884) 2023-05-29 17:14:00 -04:00
4240af86ca
Remove websocket code (#2878)
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-05-29 10:44:20 -04:00
df57795595 Dont retry outgoing HTTP requests (ref #2865) 2023-05-18 16:34:52 +02:00
Dessalines
88a0d2feec
Adding typescript generation for API. Fixes #2824 (#2827)
* Adding typescript generation for API. Fixes #2824

* Try to fix Ltree issue 1.

* Forgot a few types.

* Fixing api tests.

* Removing url_serde line.

* Manually deriving TS for some types.
2023-04-26 00:26:10 -04:00