Commits (732)
......@@ -7,11 +7,11 @@ root = true
end_of_line = lf
charset = utf-8
[*.yml]
[*.{yml,html}]
indent_style = space
indent_size = 2
[{client,server,shared}/**.{ts,json,js}]
[{client,server,shared,scripts}/**.{ts,json,js}]
trim_trailing_whitespace = true
insert_final_newline = true
indent_style = space
......
......@@ -38,12 +38,15 @@
}
}
],
"quotes": "off",
"@typescript-eslint/indent": [
"error",
2,
{
"SwitchCase": 1,
"MemberExpression": "off"
"MemberExpression": "off",
// https://github.com/eslint/eslint/issues/15299
"ignoredNodes": ["PropertyDefinition"]
}
],
"@typescript-eslint/consistent-type-assertions": [
......@@ -76,7 +79,14 @@
"@typescript-eslint/dot-notation": "off",
"@typescript-eslint/method-signature-style": "off",
"@typescript-eslint/no-base-to-string": "off",
"@typescript-eslint/quotes": "off",
"@typescript-eslint/quotes": [
"error",
"single",
{
"avoidEscape": true,
"allowTemplateLiterals": true
}
],
"@typescript-eslint/no-var-requires": "off",
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/promise-function-async": "off",
......
......@@ -116,6 +116,9 @@ $ sudo -u postgres psql -c "CREATE EXTENSION pg_trgm;" peertube_dev
$ sudo -u postgres psql -c "CREATE EXTENSION unaccent;" peertube_dev
```
Peertube also requires a running redis server, no special setup is needed for
this.
In dev mode, administrator username is **root** and password is **test**.
### Online development
......@@ -216,7 +219,19 @@ Instance configurations are in `config/test-{1,2,3}.yaml`.
To test emails with PeerTube:
* Run [mailslurper](http://mailslurper.com/)
* Run PeerTube using mailslurper SMTP port: `NODE_CONFIG='{ "smtp": { "hostname": "localhost", "port": 2500, "tls": false } }' NODE_ENV=test npm start`
* Run PeerTube using mailslurper SMTP port: `NODE_CONFIG='{ "smtp": { "hostname": "localhost", "port": 2500, "tls": false } }' NODE_ENV=dev node dist/server`
### Environment variables
PeerTube can be configured using environment variables.
See the list on https://docs.joinpeertube.org/maintain-configuration?id=environment-variables
Additionally to these ones, we provide some environment for dev/test purpose:
* `PRODUCTION_CONSTANTS=true`: in `NODE_ENV=dev` or `NODE_ENV=test` PeerTube customizes some constants. To prevent this behaviour, you can set `PRODUCTION_CONSTANTS` env to
`true`
* `PEERTUBE_LOCAL_CONFIG`: directory to find the local configuration file (used by web admin)
* `NODE_DB_LOG=false`: disable SQL request logging
## Plugins & Themes
......
---
name: 🐛 Bug Report
about: Use this template for reporting a bug
---
<!--
Please read FAQ.md and docs.joinpeertube.org first.
Please make sure your issue doesn't stem from a third-party plugin.
Please search among past open/closed issues for a similar one beforehand:
- https://github.com/Chocobozzz/PeerTube/issues?q=
- https://framacolibri.org/c/peertube
All done? Then please fill the following mandatory form to help us triage your issue.
-->
**Describe the current behavior**
**Steps to reproduce:**
1.
2.
3.
**Describe the expected behavior**
**Additional information**
* PeerTube instance:
* URL:
* version:
* NodeJS version:
* Ffmpeg version:
* Browser name, version and platforms on which you could reproduce the bug:
* Link to browser console log if relevant:
* Link to server log if relevant (`journalctl` or `/var/www/peertube/storage/logs/`):
name: 🐛 Bug Report
description: Use this template for reporting a bug
body:
- type: markdown
attributes:
value: |
Please search among past open/closed issues for a similar one beforehand:
- https://github.com/Chocobozzz/PeerTube/issues?q=
- https://framacolibri.org/c/peertube
- type: textarea
attributes:
label: Describe the current behavior
- type: textarea
attributes:
label: Steps to reproduce
value: |
1.
2.
3.
- type: textarea
attributes:
label: Describe the expected behavior
- type: textarea
attributes:
label: Additional information
value: |
* PeerTube instance:
* URL:
* Version:
* NodeJS version:
* Ffmpeg version:
* Browser name, version and platforms on which you could reproduce the bug:
* Link to browser console log if relevant:
* Link to server log if relevant (`journalctl` or `/var/www/peertube/storage/logs/`):
---
name: 🚀 Installation Issue
about: Use this template for build/installation issues
---
<!--
Please read the FAQ.md and docs.joinpeertube.org first.
Please make sure your issue doesn't stem from a third-party package.
Please search among past open/closed issues for a similar one beforehand.
All done? Then please fill the following mandatory form to help us triage your issue.
-->
**Describe the problem**
**Provide the exact sequence of commands / steps that you executed before running into the problem**
**Additional information**
* PeerTube instance:
* version:
* NodeJS version:
* Ffmpeg version:
* Redis version:
* PostgreSQL version:
<!--
Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached, not pasted.
Don't forget to check `journalctl` or `/var/www/peertube/storage/logs/`
-->
name: 🚀 Installation/Upgrade Issue
description: Use this template for build/installation/upgrade issues
body:
- type: markdown
attributes:
value: |
Please check the official documentation first:
- Classic installation: https://docs.joinpeertube.org/install-any-os
- Docker installation: https://docs.joinpeertube.org/install-docker
- type: markdown
attributes:
value: |
Please search among past open/closed issues for a similar one beforehand:
- https://github.com/Chocobozzz/PeerTube/issues?q=
- https://framacolibri.org/c/peertube
- type: textarea
attributes:
label: Describe the problem
- type: textarea
attributes:
label: Additional information
value: |
* PeerTube instance URL:
* PeerTube version:
* NodeJS version:
* Ffmpeg version:
* Redis version:
* PostgreSQL version:
---
name: 📝 Documentation Issue
about: Use this template for documentation-related issues
labels: 'Component: Documentation :books:'
assignees: rigelk
---
<!--
Please read FAQ.md and docs.joinpeertube.org first.
Please search among past open/closed issues for a similar one beforehand:
- https://github.com/Chocobozzz/PeerTube/issues?q=
- https://framacolibri.org/c/peertube
All done? Then please fill the following mandatory form to help us triage your issue.
-->
**Parts of the documentation concerned:**
<!--
Please provide a link to the documentation entry, for example: https://docs.joinpeertube.org/#/install-any-os
-->
**Describe the desired information/correction**
<!--
Are you up to submit a pull request? Chances are, only a small edit is required, so give it a try:
- click "Edit this page" if on docs.joinpeertube.org
- edit https://github.com/Chocobozzz/PeerTube/blob/develop/support/doc/api/openapi.yaml if on https://docs.joinpeertube.org/api-rest-reference.html
-->
name: 📝 Documentation Issue
description: Use this template for documentation-related issues
labels: [ 'Component: Documentation :books:' ]
body:
- type: markdown
attributes:
value: |
Please search among past open/closed issues for a similar one beforehand:
- https://github.com/Chocobozzz/PeerTube/issues?q=
- https://framacolibri.org/c/peertube
- type: textarea
attributes:
label: Describe the desired information/correction
description: |
Are you up to submit a pull request? Chances are, only a small edit is required, so give it a try:
* Click "Edit this page" if on https://docs.joinpeertube.org
* Edit https://github.com/Chocobozzz/PeerTube/blob/develop/support/doc/api/openapi.yaml if on https://docs.joinpeertube.org/api-rest-reference.html
---
name: ✨ Feature Request
about: Use this template to ask for new features and suggest new ideas 💡
---
<!--
Please read FAQ.md and docs.joinpeertube.org first.
Please search among past open/closed issues for a similar one beforehand:
- https://github.com/Chocobozzz/PeerTube/issues?q=
All done? Then please fill the following mandatory form to help us triage your request.
-->
**Describe the problem to be solved**
<!--
Provide a clear and concise description of what the problem is.
Ex. I have an issue when [...]
-->
**Describe the solution you would like:**
<!--
Provide a clear and concise description of what you want to happen.
-->
**Describe alternatives you have considered** <!-- optional -->
<!-- Remove if you have not considered alternatives.
Let us know about other solutions you have tried or researched.
-->
---
name: ✨ Feature Request
description: Use this template to ask for new features and suggest new ideas 💡
body:
- type: markdown
attributes:
value: |
Please search among past open/closed issues for a similar one beforehand:
- https://github.com/Chocobozzz/PeerTube/issues?q=
- https://framacolibri.org/c/peertube
- type: textarea
attributes:
label: Describe the problem to be solved
description: Provide a clear and concise description of what the problem is
- type: textarea
attributes:
label: Describe the solution you would like
description: Provide a clear and concise description of what you want to happen
......@@ -12,12 +12,12 @@ runs:
steps:
- name: Use Node.js
uses: actions/setup-node@v1
uses: actions/setup-node@v3
with:
node-version: ${{ inputs.node-version }}
- name: Cache Node.js modules
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: |
**/node_modules
......
......@@ -31,7 +31,7 @@ jobs:
PGHOST: localhost
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: './.github/actions/reusable-prepare-peertube-build'
with:
......
......@@ -35,7 +35,7 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@v3
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
......
......@@ -15,7 +15,7 @@ jobs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
ref: master
- name: Set matrix for build
......@@ -58,7 +58,7 @@ jobs:
-
name: Checkout develop
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
ref: ${{ matrix.ref }}
-
......
......@@ -12,7 +12,7 @@ jobs:
steps:
-
name: Checkout develop
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
ref: develop
......
......@@ -18,7 +18,7 @@ jobs:
CI_BRANCH_BASE: develop
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: './.github/actions/reusable-prepare-peertube-build'
with:
......
......@@ -48,7 +48,7 @@ jobs:
ENABLE_OBJECT_STORAGE_TESTS: true
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: './.github/actions/reusable-prepare-peertube-build'
with:
......@@ -57,7 +57,7 @@ jobs:
- uses: './.github/actions/reusable-prepare-peertube-run'
- name: Cache fixtures
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: |
fixtures
......@@ -82,7 +82,6 @@ jobs:
run: |
( \
test -f dist/scripts/parse-log.js && \
cat *-ci.log | uniq -c && \
NODE_ENV=test node dist/scripts/parse-log.js -l error -f artifacts/*.log \
) || \
echo "parse-log.js script does not exist, skipping."
......
# Changelog
## v4.3.0
### Maintenance
* Use `yt-dlp` by default instead of `youtube-dl` for new installations (because of much more dev activity)
* Support NodeJS 18
* Improved PeerTube logs:
* Reduce amount of PeerTube error logs
* Introduce `log.log_tracker_unknown_infohash` setting to disable "Unknown infoHash" warnings
* Web browsers send their error logs to the server that writes them in its own logs. Can be disabled by `log.accept_client_log` setting
* Introduce experimental support of [OpenTelemetry](https://opentelemetry.io/)
* Enable metrics export using a Prometheus exporter
* Enable tracing export using a Jaeger exporter
* Automatically rebuild native plugin modules on NodeJS ABI change
### Docker
* Add ability to easily use the docker compose stack on localhost
### Plugins/Themes/Embed API
* Theme:
* Removed unused `--secondaryColor` CSS variable
* Add client plugin hooks (https://docs.joinpeertube.org/api-plugins):
* `filter:api.my-library.video-playlist-elements.list.params` & `filter:api.my-library.video-playlist-elements.list.result` [#5098](https://github.com/Chocobozzz/PeerTube/pull/5098)
* `action:video-channel-create.init`
* `action:video-channel-update.init` & `action:video-channel-update.video-channel.loaded`
* `action:video-channel-videos.init` & `action:video-channel-videos.video-channel.loaded` & `action:video-channel-videos.videos.loaded`
* `action:video-channel-playlists.init` & `action:video-channel-playlists.video-channel.loaded` & `action:video-channel-playlists.playlists.loaded`
* `filter:share.video-embed-code.build.params` & `filter:share.video-embed-code.build.result` & `filter:share.video-playlist-embed-code.build.params` & `filter:share.video-playlist-embed-code.build.result`
* `filter:share.video-embed-url.build.params` & `filter:share.video-embed-url.build.result` & `filter:share.video-playlist-embed-url.build.params` & `filter:share.video-playlist-embed-url.build.result`
* `filter:share.video-url.build.params` & `filter:share.video-url.build.result` & `filter:share.video-playlist-url.build.params` & `filter:share.video-playlist-url.build.result`
* `action:modal.share.shown`
* Add server plugin hooks (https://docs.joinpeertube.org/api-plugins):
* `filter:job-queue.process.params` & `filter:job-queue.process.result`
* `filter:transcoding.manual.resolutions-to-transcode.result` & `filter:transcoding.auto.resolutions-to-transcode.result`
* `action:api.video-channel.created` & `action:api.video-channel.updated` & `action:api.video-channel.deleted`
* `action:notifier.notification.created`
* Add HTML placeholder (https://docs.joinpeertube.org/contribute-plugins?id=html-placeholder-elements):
* `share-modal-playlist-settings` & `share-modal-video-settings`
### Features
* :tada: Add ability for users to synchronize a remote channel [#5135](https://github.com/Chocobozzz/PeerTube/pull/5135) :tada:
* Automatically import all videos of a remote channel in your PeerTube channel
* PeerTube will watch for new publications and automatically import these new videos
* UI:
* Redesigned *Create an account* steps
* Improved *Login* page
* Use a lighter font color
* Use a bigger font size
* Don't display form errors in red while typing but only when we unfocus the input
* Display an error message when the user is unauthorized to view a page [#5097](https://github.com/Chocobozzz/PeerTube/pull/5097)
* Display latest upload date for captions
* Add an information if the live will be saved as a replay when displaying live sessions
* Move search bar at the center of the header
* Add *Toki Pona* and *Croatian* locales in client
* Embed:
* Display a message and automatically start live streams in embed
* Use the instance name instead of "PeerTube" in embed control bar
* Reuse current watch page query parameters for embed when using OEmbed [#5023](https://github.com/Chocobozzz/PeerTube/pull/5023)
* Instance follows:
* Introduce a *Rejected* state for follow requests to not reprocess already rejected follow requests
* Add bulk actions on instance following/followers ()
* Admins:
* Add ability to disable original resolution transcoding of the uploaded video/live stream
* Add ability to delete a specific video file in videos overview
* Display *Last Login* column by default in users overview
* Remember last selected columns in users overview
* Add ability to set a custom video import timeout
* Add ability to set the default feed (Atom, RSS...) items count
* Admins and moderators now bypass API rate limits
* Add ability to list comments on local videos in comments overview
* Limit video import resolution depending on enabled VOD transcoding resolutions
* Store and display the uploaded video original filename [#4885](https://github.com/Chocobozzz/PeerTube/pull/4885)
* Add *Total views* in the my channels list [#5007](https://github.com/Chocobozzz/PeerTube/pull/5007)
* Add *Original Publication Date* video sort option [#4959](https://github.com/Chocobozzz/PeerTube/pull/4959)
* Performance:
* Optimized view/watching endpoint
* Optimized video feed SQL query
* Process images (resize, convert...) in a dedicated worker thread
* Optimized emoji markup list rendering in client
* Use a worker thread to send ActivityPub Broadcast requests
* Suffix external auth username/channel name on conflict instead of throwing an exception
### Bug fixes
* Fix users overview *Last login* sort in admin
* More robust *move to object storage* job failure
* Fix comment add avatar with a unauthenticated user
* Fix fetching unlisted video in client
* Fix comments/download enabled attributes when importing a video
* Fix total instance views stats
* Fix HLS player infinite buffering on seek
* Reset table pagination on search
* *Host* search filter can also search into channels and playlists in global search
* Fix *My videos* invalid counter
* Prevent error on highlighted thread
* Fix *Jobs*, *Account blocklist* and *Server blocklist* hidden columns on Safari
* Fix live stream max bitrate
* Fix incompatibility with OpenSSL 3
* Don't crash on redis connection error
* Transcoding:
* Fix failed transcoding with a mp3 file that contains a cover image
* Prevent duplicated HLS playlist when running transcoding
* Regenerate video file names when running transcoding manually
* Prevent job failures resulting in broken videos on concurrent transcoding
* Fix transcoding of videos with quad audio channels
* ActivityPub
* Fix random invalid HTTP signature generation
* Use unique AP id for *Accept*/*Reject* activities
* Correctly handle remote actors that don't have follow counters
* Correctly handle unknown remote actor image size
* Add years in graph legend when grouping video views stats by month
* Prevent creating multiple lives when clicking multiple times on the "Go Live" button
* Fix *undefined" resolution in player *Stats for nerds*
* Fix not displayed error message in administrator web config
* More robust S3 upload [#5231](https://github.com/Chocobozzz/PeerTube/pull/5231)
* Fix broken saved live stream with only one resolution
* Fix `removeEventListener` player embed api
* Progressively cleanup actor images without width from the database
* Fix broken dates on localized pages
* Prevent job queue to be started before plugins
* Fix old database enum names
* Don't display remove file icon in admin videos overviews if we can't delete the file
## v4.2.2
### IMPORTANT NOTES
......@@ -50,10 +177,11 @@
### IMPORTANT NOTES
* **Important** SQL migrations (in particular `0685-multiple-actor-images`) can take several minutes to complete
* **Important** You need to execute manually a migration script (can be executed after your upgrade, while your PeerTube instance is running) to generate smaller avatar miniatures:
* Classic installation: `cd /var/www/peertube/peertube-latest && sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production node dist/scripts/migrations/peertube-4.2.js`
* Docker installation: `cd /var/www/peertube-docker && docker-compose exec -u peertube peertube node dist/scripts/migrations/peertube-4.2.js`
* **Important** SQL migrations (in particular `0685-multiple-actor-images`) can take several minutes to complete
* **Important** You must update your nginx configuration to support video web editor: https://docs.joinpeertube.org/install-any-os?id=nginx
* REST API:
* `PUT /api/v1/videos/{id}/watching` is deprecated, use `POST /api/v1/videos/videos/{id}/views` instead: https://docs.joinpeertube.org/api-rest-reference.html#operation/addView
......
......@@ -29,7 +29,7 @@
"arrow-body-style": "off",
"import/no-webpack-loader-syntax": "off",
"no-underscore-dangle": "off",
"node/no-callback-literal": "off",
"n/no-callback-literal": "off",
"@angular-eslint/component-selector": [
"error",
{
......