From f273014388afaf78cb003e607843f848c1e98824 Mon Sep 17 00:00:00 2001 From: pitchum Date: Fri, 24 Nov 2017 17:46:43 +0100 Subject: [PATCH] Updated Debian Jessie production installation guide (markdown) --- ...an-Jessie-production-installation-guide.md | 25 ++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/Debian-Jessie-production-installation-guide.md b/Debian-Jessie-production-installation-guide.md index f260791..f922316 100644 --- a/Debian-Jessie-production-installation-guide.md +++ b/Debian-Jessie-production-installation-guide.md @@ -15,7 +15,7 @@ We need to install dependencies: We need to create the database: sudo -u postgres createuser -P peertube - sudo -u postgres createdb -O peertube peertube + sudo -u postgres createdb -O peertube peertube_prod # User We need to create the peertube user: @@ -70,6 +70,29 @@ Copy the service file: Update the service file: sudo vim /etc/systemd/system/peertube.service + +It should look like this: + + [Unit] + Description=PeerTube daemon + + [Service] + Type=simple + Environment=NODE_ENV=production + User=peertube + Group=peertube + ExecStart=/usr/bin/npm start + WorkingDirectory=/home/peertube/PeerTube/ + StandardOutput=syslog + StandardError=syslog + SyslogIdentifier=peertube + Restart=always + + [Install] + WantedBy=multi-user.target + +Then tell systemd to reload its config: + sudo systemctl daemon-reload # Run PeerTube -- 2.25.1