]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - support/doc/tools.md
Remove traefik docker support
[github/Chocobozzz/PeerTube.git] / support / doc / tools.md
index 1f1e52c36dc58a68932f005fceb15255434c4e0d..62ba52111db399a30dff88e35c0f12baac9ffb44 100644 (file)
@@ -39,7 +39,7 @@ You need to follow all the following steps even if you are on a PeerTube server
 ### Dependencies
 
 Install the [PeerTube dependencies](dependencies.md) except PostgreSQL and Redis.
-PeerTube only supports NodeJS 10.x.
+PeerTube supports NodeJS 12.
 
 ### Installation
 
@@ -239,6 +239,7 @@ These scripts should be run on the server, in `peertube-latest` directory.
 To parse PeerTube last log file:
 
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run parse-log -- --level info
 ```
 
@@ -249,17 +250,21 @@ $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production
 You can use this script to force transcoding of an existing video. PeerTube needs to be running.
 
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run create-transcoding-job -- -v [videoUUID]
 ```
 
 Or to transcode to a specific resolution:
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run create-transcoding-job -- -v [videoUUID] -r [resolution]
 ```
+The resolution should be an integer (`1080`, `720`, `480`, etc.)
 
 To generate an HLS playlist for a video:
 
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run create-transcoding-job -- --generate-hls -v [videoUUID]
 ```
 
@@ -268,6 +273,7 @@ $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production
 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.
 
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run create-import-video-file-job -- -v [videoUUID] -i [videoFile]
 ```
 
@@ -277,6 +283,7 @@ Some transcoded videos or shutdown at a bad time can leave some unused files on
 Stop PeerTube and delete these files (a confirmation will be demanded first):
 
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo systemctl stop peertube && sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run prune-storage
 ```
 
@@ -288,17 +295,20 @@ very large files that are too large for streaming. This script re-transcodes
 these videos so that they can be watched properly, even on slow connections.
 
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run optimize-old-videos
 ```
 
 
 ### update-host.js
 
+**Changing the hostname is unsupported and may be a risky operation, especially if you have already federated.**
 If you started PeerTube with a domain, and then changed it you will have
 invalid torrent files and invalid URLs in your database. To fix this, you have
-to run:
+to run the command below (keep in mind your follower instances will NOT update their URLs).
 
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run update-host
 ```
 
@@ -307,6 +317,7 @@ $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production
 To reset a user password from CLI, run:
 
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run reset-password -- -u target_username
 ```
 
@@ -319,18 +330,21 @@ If PeerTube is running, you need to restart it for the changes to take effect (w
 To install/update a plugin or a theme from the disk:
 
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run plugin:install -- --plugin-path /local/plugin/path
 ```
 
 From NPM:
 
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run plugin:install -- --npm-name peertube-plugin-myplugin
 ```
 
 To uninstall a plugin or a theme:
 
 ```
+$ cd /var/www/peertube/peertube-latest
 $ sudo -u peertube NODE_CONFIG_DIR=/var/www/peertube/config NODE_ENV=production npm run plugin:uninstall -- --npm-name peertube-plugin-myplugin
 ```