diff options
author | Thomas Citharel <tcit@tcit.fr> | 2018-01-23 08:53:15 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-01-23 08:53:15 +0100 |
commit | e5203ffa1260ee03f0f84ef6b65d57ccad5ee695 (patch) | |
tree | 8ba1b0815642625b7289f53b5a05811a7138057c /support | |
parent | 451ce9642c7be8cb2feb789105473d22909a0964 (diff) | |
download | PeerTube-e5203ffa1260ee03f0f84ef6b65d57ccad5ee695.tar.gz PeerTube-e5203ffa1260ee03f0f84ef6b65d57ccad5ee695.tar.zst PeerTube-e5203ffa1260ee03f0f84ef6b65d57ccad5ee695.zip |
Improve docs (#232)
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
Diffstat (limited to 'support')
-rw-r--r-- | support/doc/dependencies.md | 8 | ||||
-rw-r--r-- | support/doc/production.md | 24 |
2 files changed, 22 insertions, 10 deletions
diff --git a/support/doc/dependencies.md b/support/doc/dependencies.md index 2f2d4f49d..c950b357f 100644 --- a/support/doc/dependencies.md +++ b/support/doc/dependencies.md | |||
@@ -1,6 +1,6 @@ | |||
1 | # Dependencies | 1 | # Dependencies |
2 | 2 | ||
3 | ## Debian / Ubuntu | 3 | ## Debian / Ubuntu and derivatives |
4 | 4 | ||
5 | 1. Install NodeJS 8.x (current LTS): | 5 | 1. Install NodeJS 8.x (current LTS): |
6 | [https://nodejs.org/en/download/package-manager/#debian-and-ubuntu-based-linux-distributions](https://nodejs.org/en/download/package-manager/#debian-and-ubuntu-based-linux-distributions) | 6 | [https://nodejs.org/en/download/package-manager/#debian-and-ubuntu-based-linux-distributions](https://nodejs.org/en/download/package-manager/#debian-and-ubuntu-based-linux-distributions) |
@@ -9,8 +9,8 @@ | |||
9 | 4. Run: | 9 | 4. Run: |
10 | 10 | ||
11 | ``` | 11 | ``` |
12 | $ apt-get update | 12 | $ sudo apt update |
13 | $ apt-get install nginx ffmpeg postgresql openssl g++ make | 13 | $ sudo apt install nginx ffmpeg postgresql openssl g++ make |
14 | ``` | 14 | ``` |
15 | 15 | ||
16 | ## Arch Linux | 16 | ## Arch Linux |
@@ -18,7 +18,7 @@ $ apt-get install nginx ffmpeg postgresql openssl g++ make | |||
18 | 1. Run: | 18 | 1. Run: |
19 | 19 | ||
20 | ``` | 20 | ``` |
21 | $ pacman -S nodejs yarn ffmpeg postgresql openssl | 21 | $ sudo pacman -S nodejs yarn ffmpeg postgresql openssl |
22 | ``` | 22 | ``` |
23 | 23 | ||
24 | ## Other distributions | 24 | ## Other distributions |
diff --git a/support/doc/production.md b/support/doc/production.md index 49569dad4..ee8bf2647 100644 --- a/support/doc/production.md +++ b/support/doc/production.md | |||
@@ -12,12 +12,16 @@ Create a `peertube` user with `/home/peertube` home: | |||
12 | 12 | ||
13 | ``` | 13 | ``` |
14 | $ sudo useradd -m -d /home/peertube -s /bin/bash -p peertube peertube | 14 | $ sudo useradd -m -d /home/peertube -s /bin/bash -p peertube peertube |
15 | ``` | ||
16 | |||
17 | Set its password: | ||
18 | ``` | ||
15 | $ sudo passwd peertube | 19 | $ sudo passwd peertube |
16 | ``` | 20 | ``` |
17 | 21 | ||
18 | ### Database | 22 | ### Database |
19 | 23 | ||
20 | Create production database and peertube user: | 24 | Create the production database and a peertube user inside PostgreSQL: |
21 | 25 | ||
22 | ``` | 26 | ``` |
23 | $ sudo -u postgres createuser -P peertube | 27 | $ sudo -u postgres createuser -P peertube |
@@ -26,13 +30,21 @@ $ sudo -u postgres createdb -O peertube peertube_prod | |||
26 | 30 | ||
27 | ### Prepare PeerTube directory | 31 | ### Prepare PeerTube directory |
28 | 32 | ||
33 | Fetch the latest tagged version of Peertube | ||
34 | ``` | ||
35 | $ VERSION=$(curl -s https://api.github.com/repos/chocobozzz/peertube/releases/latest | grep tag_name | cut -d '"' -f 4) && echo "Latest Peertube version is $VERSION" | ||
36 | ``` | ||
37 | Open the peertube directory, create a few required directories | ||
38 | ``` | ||
39 | cd /home/peertube && sudo -u peertube mkdir config storage versions && cd versions | ||
40 | ``` | ||
41 | Download the latest version of the Peertube client, unzip it and remove the zip | ||
29 | ``` | 42 | ``` |
30 | $ VERSION=$(curl -s https://api.github.com/repos/chocobozzz/peertube/releases/latest | grep tag_name | cut -d '"' -f 4) && \ | ||
31 | cd /home/peertube && \ | ||
32 | sudo -u peertube mkdir config storage versions && \ | ||
33 | cd versions && \ | ||
34 | sudo -u peertube wget -q "https://github.com/Chocobozzz/PeerTube/releases/download/${VERSION}/peertube-${VERSION}.zip" && \ | 43 | sudo -u peertube wget -q "https://github.com/Chocobozzz/PeerTube/releases/download/${VERSION}/peertube-${VERSION}.zip" && \ |
35 | sudo -u peertube unzip peertube-${VERSION}.zip && sudo -u peertube rm peertube-${VERSION}.zip && \ | 44 | sudo -u peertube unzip peertube-${VERSION}.zip && sudo -u peertube rm peertube-${VERSION}.zip |
45 | ``` | ||
46 | Install Peertube | ||
47 | ``` | ||
36 | cd ../ && sudo -u peertube ln -s versions/peertube-${VERSION} ./peertube-latest && \ | 48 | cd ../ && sudo -u peertube ln -s versions/peertube-${VERSION} ./peertube-latest && \ |
37 | cd ./peertube-latest && sudo -u peertube yarn install --production --pure-lockfile | 49 | cd ./peertube-latest && sudo -u peertube yarn install --production --pure-lockfile |
38 | ``` | 50 | ``` |