Commit Graph

341 Commits

Author SHA1 Message Date
Chocobozzz
28e51e831b
Oup's 2018-10-17 17:58:21 +02:00
Chocobozzz
0229b014e0
Fix tests 2018-10-17 13:10:58 +02:00
Chocobozzz
bb5d90e62f
Merge branch 'feature/webtorrent-disabling' into develop 2018-10-17 10:48:56 +02:00
Felix Ableitner
bcf21a376f Set keyframe interval for transcoding (fixes #1147) (#1231)
* Set keyframe interval for transcoding (fixes #1147)

* remove -maxrate and old bitrate setter

* pass fps as parameter

* set type for ffmpeg param

* assign ffmpeg object
2018-10-17 10:15:38 +02:00
Chocobozzz
7ad9b9846c Add ability for users to block an account/instance on server side 2018-10-16 16:41:36 +02:00
Rigel Kent
ed638e5325
move to boolean switch 2018-10-13 11:53:48 +02:00
Rigel Kent
64cc5e8575
add webtorrent opt-out settings
- add a key in localstorage to remember the opt-out
- add a user setting
2018-10-13 11:53:42 +02:00
BRAINS YUM
0e5ff97f6f add parseBytes utility function and tests (#1239)
* add parseBytes utility function and tests
make it parse TB MB
fix parseBytes; * 1024
test bytes too, and make parseByte to parse quotas
add test in travis.sh in misc

* fix parseBytes and test to pass linting
2018-10-13 08:43:55 +02:00
Chocobozzz
71e318b4fe
Merge branch 'release/v1.0.0' into develop 2018-10-11 09:52:16 +02:00
Chocobozzz
1cd3facc3d
Add ability to list all local videos
Including private/unlisted for moderators/admins
2018-10-10 11:46:50 +02:00
Chocobozzz
729bb18481
Add more headers to broadcast/unicast 2018-10-10 08:51:58 +02:00
Rigel Kent
e1d7b98bc7
fix automatic bitrate adjustment
The regression was introduced in
edb4ffc7e0 and forced a fixed bitrate per
resolution
2018-10-08 21:14:21 +02:00
Felix Ableitner
edb4ffc7e0 Set bitrate limits for transcoding (fixes #638) (#1135)
* Set bitrate limits for transcoding (fixes #638)

* added optimization script and test, changed stuff

* fix test, improve docs

* re-add optimize-old-videos script

* added documentation

* Don't optimize videos without valid UUID, or redundancy videos

* move getUUIDFromFilename

* fix tests?

* update torrent and file size, some more fixes/improvements

* use higher bitrate for high fps video, adjust bitrates

* add test video

* don't throw error if resolution is undefined

* generate test fixture on the fly

* use random noise video for bitrate test, add promise

* shorten test video to avoid timeout

* use existing function to optimize video

* various fixes

* increase test timeout

* limit test fixture size, add link

* test fixes

* add await

* more test fixes, add -b:v parameter

* replace ffmpeg wiki link

* fix ffmpeg params

* fix unit test

* add test fixture to .gitgnore

* add video transcoding fps model

* add missing file
2018-10-08 16:26:04 +02:00
Chocobozzz
6e46de095d
Add user history and resume videos 2018-10-05 11:22:38 +02:00
Chocobozzz
499d901595
Fix config endpoint 2018-10-03 14:36:00 +02:00
Chocobozzz
c049d791f9
Check the comment is defined when validating body 2018-10-01 19:07:25 +02:00
Chocobozzz
a3737cbf2b
Fix video fps validator 2018-10-01 16:27:47 +02:00
Chocobozzz
7361c401b1
Decrease log file max size 2018-10-01 15:20:13 +02:00
Rigel Kent
abb2c7927c show last commit hash alongside server version in footer 2018-10-01 14:31:01 +02:00
Chocobozzz
cf9166cf2f
Add timeout on youtube dl to cleaup files 2018-10-01 12:00:05 +02:00
Chocobozzz
e37c85e933
Delete each file on failed import 2018-10-01 10:52:58 +02:00
Chocobozzz
d0b52b5285
Correctly delete directories on import 2018-09-28 09:08:12 +02:00
Chocobozzz
cc68049424
Fix video import of some youtube videos 2018-09-26 15:55:45 +02:00
Chocobozzz
a71de50bbc
Correctly fix the webtorrent redundancy bug 2018-09-26 08:50:21 +02:00
Chocobozzz
69fa54a0b2
Dirty webtorrent fix to wait FS sync 2018-09-25 19:42:05 +02:00
Chocobozzz
c922d14220
Fix redundancy bug with old peertube torrent 2018-09-25 17:49:50 +02:00
lsde
7e7ab7a15d Add dot into allowed actor username
One should have an oportunity to include a dot into the username.
Currently, it breaks the flow if one has an SSO in front of PeeTube which creates users with "name.surname".
2018-09-25 11:41:15 +02:00
Chocobozzz
e5565833f6
Improve redundancy: add 'min_lifetime' configuration 2018-09-24 13:38:39 +02:00
Chocobozzz
d1a63fc7ac
Fix videos list user NSFW policy 2018-09-24 13:38:38 +02:00
Chocobozzz
00f9e41ebf
Add warning if one of the storage directory is in the peertube
production directory

Because admins could loose these directories on peertube upgrade
2018-09-20 16:25:00 +02:00
Chocobozzz
0491173a61
Merge branch 'develop' into cli-wrapper 2018-09-20 16:24:31 +02:00
Chocobozzz
f41d6aacdf
Fix jobs tests 2018-09-19 17:42:16 +02:00
Chocobozzz
993cef4b6e
Refractor audit user identifier 2018-09-19 17:02:27 +02:00
Chocobozzz
606c946e74
Move youtubeDL upgrader in helpers/ 2018-09-19 16:24:24 +02:00
Chocobozzz
e587e0ecee
Optimize activity actor load in AP processors 2018-09-19 15:22:55 +02:00
Chocobozzz
4157cdb137
Refractor videos AP functions 2018-09-19 11:16:23 +02:00
Chocobozzz
96f29c0f6d
Optimize SQL requests of videos AP endpoints 2018-09-19 10:20:38 +02:00
Chocobozzz
627621c1e8
Optimize SQL requests of watch page API endpoints 2018-09-19 09:54:37 +02:00
Chocobozzz
dae4a1c0f8
Improve webtorrent import error message when the torrent has multiple
files
2018-09-17 17:50:51 +02:00
Chocobozzz
2ff83ae292
Handle actors search beginning with '@'
Something like @toto@example.com
2018-09-17 10:13:54 +02:00
Chocobozzz
7348b1fd84
Speed up overviews route 2018-09-14 11:52:23 +02:00
Rigel Kent
8704acf49e
one cli to unite them all
Ash nazg thrakatulûk agh burzum-ishi krimpatul

- refactor import-videos to use the youtubeDL helper
- add very basic tests for the cli
2018-09-14 11:08:55 +02:00
Chocobozzz
3f6b6a565d
Add recently added redundancy strategy 2018-09-14 11:05:38 +02:00
Chocobozzz
c48e82b5e0 Basic video redundancy implementation 2018-09-13 14:05:49 +02:00
Rigel Kent
e78980ebd1 use focus-visible polyfill to improve keyboard navigation
Only the homepage is concerned, but it should have decent keyboard
navigation support now.
2018-09-11 10:58:48 +02:00
Chocobozzz
1a893f9c70
Do not import live streaming 2018-09-04 11:55:43 +02:00
Chocobozzz
5d112d0c3b
Fix video import with URL with small titles 2018-09-04 11:34:46 +02:00
Chocobozzz
eb87f9a4a9
Fix nsfw filter 2018-09-04 11:19:19 +02:00
Chocobozzz
5cf84858d4
Add federation to ownership change 2018-09-04 10:49:53 +02:00
Gaëtan Rizio
74d6346935 Users can change ownership of their video [#510] (#888)
* [#510] Create a new route to get the list of user names

To be able to transfer ownership to a user,
we need to be able to select him from the list of users.

Because the list could be too big, we add a autocomplete feature.

This commit does the following:

* Add a API endpoint to get a list of user names by searching its name

* [#510] The user can choose the next owner of the video

To be able to transfer ownership to a user,
we need the owner to be able to select the user.

The server can autocomplete the name of the user to give the ownership.
We add a dialog for the user to actually select it.

This commit does the following:

* Create a modal for the owner to select the next one
* Opens this modal with a button into the menu *more*
* Make the dependency injection

* [#510] When the user choose the next owner, create a request in database

For the change of ownership to happen, we need to store the temporary requests.
When the user make the request, save it to database.

This commit does the following:

* Create the model to persist change ownership requests
* Add an API to manage ownership operations
* Add a route to persist an ownership request

* [#510] A user can fetch its ownership requests sent to him

To be able to accept or refuse a change of ownership,
the user must be able to fetch them.

This commit does the following:

* Add an API to list ownership for a user
* Add the query to database model

* [#510] A user can validate an ownership requests sent to him - server

The user can accept or refuse any ownership request that was sent to him.
This commit focus only on the server part.

This commit does the following:

* Add an API for the user to accept or refuse a video ownership
* Add validators to ensure security access
* Add a query to load a specific video change ownership request

* [#510] A user can validate an ownership requests sent to him - web

The user can accept or refuse any ownership request that was sent to him.
This commit focus only on the web part.

This commit does the following:

* Add a page to list user ownership changes
* Add actions to accept or refuse them
* When accepting, show a modal requiring the channel to send the video

* Correct lint - to squash

* [#510] PR reviews - to squash

This commit does the following:

* Search parameter for user autocompletion is required from middleware directly

* [#510] PR reviews - to squash with creation in database commit

This commit does the following:

* Add the status attribute in model
* Set this attribute on instance creation
* Use AccountModel method `loadLocalByName`

* [#510] PR reviews - to squash with fetch ownership

This commit does the following:

* Add the scope `FULL` for database queries with includes
* Add classic pagination middlewares

* [#510] PR reviews - to squash with ownership validation - server

This commit does the following:

* Add a middleware to validate whether a user can validate an ownership
* Change the ownership status instead of deleting the row

* [#510] PR reviews - to squash with ownership validation - client

This commit does the following:

* Correct indentation of html files with two-spaces indentation
* Use event emitter instead of function for accept event
* Update the sort of ownership change table for a decreasing order by creation date
* Add the status in ownership change table
* Use classic method syntax

* code style - to squash

* Add new user right - to squash

* Move the change to my-account instead of video-watch - to squash

As requested in pull-request, move the action to change ownership into my videos page.

The rest of the logic was not really changed.

This commit does the following:

- Move the modal into my video page
- Create the generic component `button` to keep some styles and logic

* [#510] Add tests for the new feature

To avoid regression, we add tests for all api of ownership change.

This commit does the following:

- Create an end-to-end test for ownership change
- Divide it to one test per request

* [#510] Do not send twice the same request to avoid spam

We can send several time the same request to change ownership.
However, it will spam the user.
To avoid this, we do not save a request already existing in database.

This commit does the following:

- Check whether the request exist in database
- Add tests to verify this new condition

* [#510] Change icons

Change icons so they remains logic with the rest of the application.

This commit does the following:

- Add svg for missing icons
- Add icons in `my-button` component
- Use these new icons

* [#510] Add control about the user quota

The user should be able to accept a new video only if his quota allows it.

This commit does the following:

- Update the middleware to control the quota
- Add tests verifying the control

* Correct merge

- Use new modal system
- Move button to new directory `buttons`

* PR reviews - to squash
2018-09-04 08:57:13 +02:00