X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=support%2Fdoc%2Ftools.md;h=1f1e52c36dc58a68932f005fceb15255434c4e0d;hb=bc90883f1a5e9c4ecb76ae358734b85be515af7f;hp=dd2a03db7363e8cbc92c4184c1f865a804194b1f;hpb=00aab0666c6f772548c160fdfa871a8843b88f37;p=github%2FChocobozzz%2FPeerTube.git diff --git a/support/doc/tools.md b/support/doc/tools.md index dd2a03db7..1f1e52c36 100644 --- a/support/doc/tools.md +++ b/support/doc/tools.md @@ -12,6 +12,7 @@ - [peertube-upload.js](#peertube-uploadjs) - [peertube-watch.js](#peertube-watchjs) - [peertube-plugins.js](#peertube-pluginsjs) + - [peertube-redundancy.js](#peertube-redundancyjs) - [Server tools](#server-tools) - [parse-log](#parse-log) - [create-transcoding-job.js](#create-transcoding-jobjs) @@ -77,7 +78,8 @@ You can access it as `peertube` via an alias in your `.bashrc` like `alias peert import-videos|import import a video from a streaming platform watch|w watch a video in the terminal ✩°。⋆ repl initiate a REPL to access internals - plugins|p [action] manag instance plugins + plugins|p [action] manage instance plugins + redundancy|r [action] manage video redundancies help [cmd] display help for [cmd] ``` @@ -124,7 +126,7 @@ $ node dist/server/tools/peertube-import-videos.js \ -u 'PEERTUBE_URL' \ -U 'PEERTUBE_USER' \ --password 'PEERTUBE_PASSWORD' \ - -t 'TARGET_URL' + --target-url 'TARGET_URL' ``` * `PEERTUBE_URL` : the full URL of your PeerTube server where you want to import, eg: https://peertube.cpy.re @@ -200,6 +202,34 @@ $ node dist/server/tools/peertube-plugins.js install --path /my/plugin/path $ node dist/server/tools/peertube-plugins.js install --npm-name peertube-theme-example ``` +#### peertube-redundancy.js + +Manage (list/add/remove) video redundancies: + +To list your videos that are duplicated by remote instances: + +``` +$ node dist/server/tools/peertube.js redundancy list-remote-redundancies +``` + +To list remote videos that your instance duplicated: + +``` +$ node dist/server/tools/peertube.js redundancy list-my-redundancies +``` + +To duplicate a specific video in your redundancy system: + +``` +$ node dist/server/tools/peertube.js redundancy add --video 823 +``` + +To remove a video redundancy: + +``` +$ node dist/server/tools/peertube.js redundancy remove --video 823 +``` + ## Server tools These scripts should be run on the server, in `peertube-latest` directory. @@ -227,6 +257,12 @@ Or to transcode to a specific resolution: $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run create-transcoding-job -- -v [videoUUID] -r [resolution] ``` +To generate an HLS playlist for a video: + +``` +$ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run create-transcoding-job -- --generate-hls -v [videoUUID] +``` + ### create-import-video-file-job.js You can use this script to import a video file to replace an already uploaded file or to add a new resolution to a video. PeerTube needs to be running.