#+TITLE: #+AUTHOR: Bob Mottram #+EMAIL: bob@freedombone.net #+KEYWORDS: freedombone, peertube #+DESCRIPTION: How to use PeerTube #+OPTIONS: ^:nil toc:nil #+HTML_HEAD: #+attr_html: :width 80% :height 10% :align center [[file:images/logo.png]] #+attr_html: :width 100% :align center [[file:images/peertube.jpg]] This is a video hosting system similar to Mediagoblin but using webtorrent to help distribute the files to or between clients. This should be more practical for situations where a video becomes popular because the load is then spread across the network, with performance increasing with the number of nodes. However, the torrenting aspect of it only works with WebRTC enabled browsers and so this means it's unlikely to fully work with a Tor browser. Without WebRTC then from a user point of view it's effectively the same thing as Mediagoblin. * Installation Log into your system with: #+begin_src bash ssh myusername@mydomain -p 2222 #+end_src Using cursor keys and Enter key select *Administrator controls* and type in your password. Select *Add/Remove Apps* then *peertube*. You will then be asked for a domain name and if you are using FreeDNS also the code for the domain which can be found under *Dynamic DNS* on the FreeDNS site (the random string from "/quick cron example/" which appears after /update.php?/ and before />>/). For more details on obtaining a domain and making it accessible via dynamic DNS see the [[./faq.html][FAQ]]. Typically the domain name you use will be a subdomain, such as /video.mydomainname.net/. It will need to be a domain which you have bought somewhere and own and not one of the FreeDNS subdomains, otherwise you won't be able to get a SSL/TLS certificate for it. Although PeerTube can handle a few formats *webm* is the currently recommended one. Other formats might not play in some browsers or on some libre distros. * Initial setup Navigate to your site and select *Signup* to create a new account. By default the maximum number of accounts on your system is limited to a small number so that millions of random internet users can't then begin uploading dubious content. After that it's pretty straightforward. If you wish it's possible to turn off further signups via the *Administrator control panel* under *App settings* for *peertube*. * Importing videos from your desktop The most convenient way to add new videos to PeerTube is if you have the *syncthing* app installed. Set up [[./app_syncthing.html][syncthing]] with a folder called ~/Sync in your home directory. Create a subdirectory called *~/Sync/peertube_upload*. Within that directory make a text file called *login.txt*. This will contain your PeerTube login details. The first line of login.txt should be your username, the second line should be the password and optionally the third line can contain the words *public* and/or *nsfw*, if you want to make imported videos immediately public or mark them as not suitable for work. Prepare your videos in *webm* or *ogv* format. Other formats may be poorly supported, especially on libre distros. To minimize bandwidth usage try to keep your videos as small as possible. Giant videos with incredibly high resolution tend to result in a bad user experience. Often just converting your videos to *webm* using *ffmpeg* will keep the size down. Now copy or drag and drop your videos into the *~/Sync/peertube_upload* directory. Syncthing will sync to the server and automatically add the videos to PeerTube. Depending on how large the videos are this may take some time. Imported videos can be seen by logging into PeerTube, selecting *My account* then the *My videos* tab. You can then view them, add a description and select to make them public if you wish. * A commons for video content By default synced videos will have a private status, so only be viewable by users who are logged in. But PeerTube is really more about creating a public commons for video. Prefer Creative Commons licensed videos and avoid uploading Hollywood movies, TV shows, non-CC music videos or anything from the [[https://en.wikipedia.org/wiki/Ancien_R%C3%A9gime][ancien régime]] of copyright, which may attract the wrong sort of legal attention. #+attr_html: :width 50% :align center [[file:images/creativecommonslogo.png]]