439 Commits
Author SHA1 Message Date
ImmaeandChocobozzz 4fd6af36e4 Recommendations policy (#7633)
* Filter recommendation policy

This commit adds a new option attached to a video, that allows to chose
which kind of recommendation will appear below it in the viewer.
It currently allows four setups:
- Any video (same as currently)
- Local videos only
- Owner videos only
- Same channel videos only

This allows the user who owns the video to restrict the recommendations
associated to his videos.

* Remove old recommendation strategy endpoints

* Add tests

Tests for the recommendation feature

* Add a stateless /api/v1/recommendations/videos route

The route accepts a strategy and (optionnally) video ID as query params,
and returns a list of recommentations associated to the video and
matching the strategy

* Add stateless recommendation endpoint: client part

* Add an admin-configurable default strategy

* Add Federation recommendation strategy information

* User import/export settings

* Translate changes to French

* Use scope instead of strategy for recommendations

---------

Co-authored-by: Chocobozzz <[email protected]>
2026-10-28 08:41:59 +01:00
Chocobozzz 0108fcb93f Store audit logs in database
Allow to centralize audit logs, even if horizontal scalability is
enabled
2026-10-27 11:16:03 +01:00
Chocobozzz f780e64289 Introduce postgresql secondaries support
Only for a few routes, that consumes postgresql CPU

Re-implement sequelize connection routing mechanism, to support:
 * Replica lag monitoring (to not select replicas that are too far
   behind the primary)
 * Be opt-in instead of opt-out (primary is used by default, a context
   must be marked to use replicas)
 * Handle "read-you-writes" mechanism (ensure that reads after writes
   see the latest data, using the user ID to track recent writes)
2026-10-16 13:47:57 +02:00
kontrollantenandChocobozzz 5a497906d7 feat(videos/browse): make it configurable to show scheduled lives (#7825)
* feat(videos/browse): make it configurable to show scheduled lives

closes #5235

* Consistency

---------

Co-authored-by: Chocobozzz <[email protected]>
2026-10-15 10:47:12 +02:00
Chocobozzz 9cee7f9bef Explain podcast audio file is stored in web videos 2026-10-14 10:29:01 +02:00
AltaifiandChocobozzz e911c75b6b Add ability to disable audit logs (#7777)
* Add ability to disable audit logs

Add a `log.audit.enabled` configuration option, mirroring the existing
`log.rotation.enabled` shape.

The guard lives in `auditLoggerWrapper`, which every `create`/`update`/
`delete` audit call routes through, so the 13 `auditLoggerFactory`
consumers need no change.

Closes #2686

* Add sort option to channel miniature markup

* Styling

---------

Co-authored-by: Chocobozzz <[email protected]>
2026-10-13 11:11:34 +02:00
m-altaifi 4b6777c83d Add ability to customize the video redundancy timeout
Mirroring a big video could not take longer than 3 hours, and the HLS
download budget was taken from `import.videos.timeout`, so raising it to
let a mirror finish also changed video import behaviour.

Add `redundancy.videos.timeout`, feeding both the `video-redundancy` job
TTL and the HLS download budget, the same way `import.videos.timeout`
already feeds `video-import`.

Closes #5519
2026-10-13 11:00:48 +02:00
Chocobozzz f0b041375b Fix tests 2026-10-06 09:02:22 +02:00
Chocobozzz dbb44f0015 Add ability to specify remote tracker
To handle large amount of viewers using P2P
2026-10-05 13:43:05 +02:00
Chocobozzz 44f27cb2db Inbox processing support in secondaries
Also support redundancy in object storage
2026-10-05 13:42:44 +02:00
Chocobozzz 86bf7f4f42 Make secondary processes rely on object storage
Simplifications:
  * object_storage.enabled is now the only switch, and check at startup
    bucket connection
  * secondaries no longer adopt the storage directories of the primary

Add remote files caching in a dedicated bucket so secondaries can lazy
static serve them

Publish the youtube-dl cookies file through Redis to support it in
secondaries

Change nginx behaviour using an denylist to secondaries (instead of an
allowlist)
2026-10-05 13:42:42 +02:00
Chocobozzz 41effc40ce Stage heavy uploads in object storage
Required step so secondary can handle file upload endpoints and handle
controllers that manage files
2026-10-05 13:41:13 +02:00
Chocobozzz fa856f7dc7 Add video files lifecycle management 2026-10-05 13:41:12 +02:00
Chocobozzz aeace7e4ca Add more supported files to object storage
actor images, thumbnails, storyboards, torrents and uploads
2026-10-05 13:41:12 +02:00
Chocobozzz 94c11329b4 Add ability to disable rate limits
Also disable login lockout by default
2026-08-24 17:54:21 +02:00
Chocobozzz b332c473c3 Add setting to enable tagging requests 2026-08-18 10:53:13 +02:00
cinereal f8bb2e0d55 Declare the configuration schema against draft 2020-12
Every keyword `scripts/generate-config-schema.ts` emits -- `type`,
`default`, `description`, `properties`, `items`, `additionalProperties`,
`enum` -- means the same thing in draft-07 and in draft 2020-12, so the
generated document already is a valid 2020-12 schema and saying so changes
nothing about which configurations it admits.

Nothing in this repository reads the keyword: `validate-config-schema.ts`
drops `$schema` before compiling with Ajv. It is there for the consumers
that do read it -- editor completion, third-party validators -- and those
implement 2020-12 where support for the older drafts is fading.

Assisted-by: Claude:claude-opus-5
2026-08-18 10:19:59 +02:00
Chocobozzz 2b6b99d2ce Add dedicated rate limiters for tokens checker 2026-07-20 15:29:41 +02:00
Chocobozzz cd9a79584d Check password length earlier 2026-07-20 13:39:04 +02:00
Chocobozzz 538f58cdbb Require multiple IPs to block an account 2026-07-20 10:50:38 +02:00
Chocobozzz 49902b88ed Configurable login lockout 2026-07-20 10:25:38 +02:00
Chocobozzz 3305fb62be Introduce per account rate limit
* For login
 * For abuse creation
 * For comment creation
2026-07-20 09:25:37 +02:00
AsyncnomiandChocobozzz 543930a547 Add cross-auth option (#7655)
* Add cross-auth option

* revert some files & no longer exposes the option to the front

* Rename setting

* add external-auth cross-provider test

* fix wrong usage of updateExistingConfig for options not part of customConfig in test

* update config-schema

---------

Co-authored-by: Chocobozzz <[email protected]>
2026-07-16 10:51:45 +02:00
Chocobozzz 741a0db3b9 Update config schema 2026-06-22 12:02:20 +02:00
cinereal 1cc0418a5f generate json schema
Uses the .yaml files to generate a JSON-Schema
describing the possible configuration options,
and add CI checks to keep this from going stale
and validate the YAML files against the schema.

Assisted-by: claude-code: claude-opus-4-7 (planning) + claude-sonnet-4-7 (execution)

Signed-off-by: cinereal <[email protected]>
2026-06-22 11:00:40 +02:00
Chocobozzz be7886287f Add explicit redis socket config 2026-06-17 14:35:54 +02:00
Chocobozzz 34ce07a55a Add auto mute subscription feature 2026-06-17 14:35:53 +02:00
Chocobozzz d8676ce469 Merge branch 'release/v8.1.x' into develop 2026-05-23 18:26:05 +02:00
Chocobozzz 182772bb77 Add ability to disable root login from config 2026-05-23 10:26:20 +02:00
Chocobozzz 596420480e Fix security expires 2026-05-20 16:15:19 +02:00
Chocobozzz 4269c93a24 Fix tests 2026-05-06 15:58:01 +02:00
Chocobozzz f9587f9e37 Add video download throttling 2026-04-20 16:30:28 +02:00
Viny Brun Kriesang fb46151616 Add cookies to yt-dlp config and docker env (#7510)
* Adds cookies to yt-dlp config and docker env

* changes after PR review
2026-04-13 09:49:21 +02:00
Chocobozzz b67738c6d1 Increase default refresh token lifetime 2026-04-01 15:02:46 +02:00
Moby Mikes 💻andChocobozzz 150962ffcf Add configurable default for live replay save option (#7414)
* Add configurable default for live replay save option

Allow admins to configure the default state of the 'automatically
publish a replay when your live ends' checkbox via a new
live.save_replay_by_default setting (defaults to false).

Fixes #6304

* refactor(config): move live replay default to defaults section

Relocate `live.save_replay_by_default` to `defaults.live.save_replay`
to better align with the configuration convention where default UI
states are grouped under the `defaults` key.

This change updates:
- Server configuration loading and exposure
- TypeScript models (ServerConfig, CustomConfig)
- Admin configuration interface
- Live creation form default value handling

Refs: #6304

* test(config): update tests for live replay default refactor

Update configuration tests to verify defaults.live.saveReplay instead of the old live.saveReplayByDefault key.

Also update config/test.yaml to match the new configuration structure.

* fix(config): update video imports test and config validator

* fixed tests

* Fix merge

* Fix default save replay in server

---------

Co-authored-by: Chocobozzz <[email protected]>
2026-03-24 15:52:05 +01:00
4d54ea4587 Live dvr (#7396)
* Add pop-out player button

* Use native PiP and hide popout fallback

* Revert Live DVR changes

* Add Live DVR with 2h window

* Add Live DVR flag in video watch player options

* Fix Live DVR seekbar and HLS options

* Show PiP button on medium player sizes

* Force PiP button visible in embed

* Disable context menu in embeds

* Match PiP icon size to other controls

* Center popout icon mask

* Center PiP control

* Add context menu flag to embed customizations

* Revert "Center PiP control"

This reverts commit aede705f3f.

* Revert "Center popout icon mask"

This reverts commit 0770471caa.

* Revert "Match PiP icon size to other controls"

This reverts commit cef0b49a02.

* Revert "Force PiP button visible in embed"

This reverts commit 1379d7d0c9.

* Revert "Show PiP button on medium player sizes"

This reverts commit a183536ca7.

* Revert object storage path-style config

* Add configurable per-live DVR window

* Remove force_path_style config dependency

* Fix DVR window validator typing

* Include DVR seconds in live form patch

* Fix logout token revocation race

* Stabilize video import and transcription tests

* Increase video transcription replacement test timeouts

* Revert "Remove force_path_style config dependency"

This reverts commit cac22d193f.

* Revert "Add pop-out player button"

This reverts commit 28ba5f5bb1.

* test(live): add DVR validation coverage

* config: define object_storage.force_path_style default

* style(lint): fix max-len in live DVR files

* style(client): fix lint in live DVR types

* feat(live): switch DVR window to milliseconds and simplify player toggle

* Live DVR adaptations

---------

Co-authored-by: DJBlu <[email protected]>
Co-authored-by: root <[email protected]>
Co-authored-by: root <[email protected]>
Co-authored-by: Chocobozzz <[email protected]>
2026-03-20 16:19:13 +01:00
Chocobozzz baa0f2e192 Add a note about tls connection with redis/pg 2026-03-18 10:53:36 +01:00
Chocobozzz 0f7280a7e4 Use lucide player theme by default
Community seems to like it, and it's a more "mainstream" video player
compared to other video platforms
2026-02-24 09:13:17 +01:00
Chocobozzz 34d816f5df Update default object storage config
Prefer using prefix so it doesn't break existing object storage
configuration when we add more settings in the future (because the new
bucket doesn't exist)
2026-02-24 09:13:17 +01:00
Chocobozzz 9204d042b9 Add config to generate podcast audio file 2026-02-23 16:31:34 +01:00
Chocobozzz 5b662c88fa Add secrets config comment 2026-02-19 16:03:18 +01:00
Chocobozzz 34dfb2aff4 Generate more video thumbnail sizes 2026-02-19 15:11:25 +01:00
Chocobozzz 72610f4d0f Check new database config key 2026-02-13 14:19:18 +01:00
pawka 3f90624333 fix: 7317 support pg ssl (#7366)
* fix: 7317 support pg ssl

* fix: return database.ssl value for tests

* feat: new database ssl_settings options

* chore: update production.yaml database ssl_settings

* chore: remove useless comment

* fix: revert ssl config
2026-02-13 14:16:22 +01:00
Chocobozzz 48cda7c4a9 Prefer enable_tls for sentinel config consistency 2026-02-13 14:14:05 +01:00
pawka e1e9636133 fix: 7317 support redis tls (#7404)
* fix: 7317 support redis ssl

* chore: sort imports

* fix(redis): save old configuration tls
2026-02-13 14:10:27 +01:00
Chocobozzz 526f1c6df5 Rebuild thumbnail and media file architecture
* Move to sharp library to improve image manipulation performance and
   support more image formats
 * Move video previews in thumbnails directory
 * Deprecate lazy static previews endpoint
 * Plugin `getFiles()` API now includes a `width`/`height` attribute
 * Deprecate previewfile for video publication/update.
   Use `thumbnailfile` instead
 * Deprecate `thumbnailPath` and `previewPath` of `Video` in favour of
   `thumbnails`
 * Deprecate `thumbnailPath` of `VideoPlaylist` in favour of
   `thumbnails`
 * Replace `torrentPath` by `torrentFilename` and `torrentStream` for
   remote torrents for `filter:api.download.torrent.allowed.result`
   plugin filter
 * Remove useless `fileUrl` from `UserExport` and `VideoSource`
 * Remove remote captions where we don't have a valid URL
 * cache directory is not deleted on each run anymore
 * Add permanent cache for video captions and storyboards
 * Remove `cache` admin configuration, use house-keeping script instead
2026-02-13 06:20:56 +01:00
Chocobozzz 73b6a95600 Optimize and more reliable channel sync
Reduce youtube-dl calls to reduce rate limiting
Handle cases where the video is not available/doesn't exist
Handle lives that are still being post-processed
Stop sync on get info failure to retry next time
2026-02-04 10:54:17 +01:00
Chocobozzz 6ecd9823cf Add "on primary" color
And force email button color
2026-01-27 10:29:31 +01:00
Chocobozzz 782720031a Force ipv4 for youtube-dl
IPv6 is automatically blocked
2026-01-22 09:32:46 +01:00