mirror of
https://github.com/retspen/webvirtcloud.git
synced 2026-05-26 15:13:33 +00:00
update novncd runit script, make it debian compatible, update docs
This commit is contained in:
11
README.md
11
README.md
@@ -213,6 +213,17 @@ Done!!
|
||||
|
||||
Go to http://serverip and you should see the login screen.
|
||||
|
||||
### Alternative running novncd via runit
|
||||
Alternative to running nonvcd via supervisor is runit.
|
||||
|
||||
On Debian systems install runit and configure novncd service
|
||||
```
|
||||
apt install runit runit-systemd
|
||||
mkdir /etc/service/novncd/
|
||||
ln -s /srv/webvirtcloud/conf/runit/novncd.sh /etc/service/novncd/run
|
||||
systemctl start runit.service
|
||||
```
|
||||
|
||||
### Default credentials
|
||||
<pre>
|
||||
login: admin
|
||||
|
||||
@@ -1,4 +1,18 @@
|
||||
#!/bin/sh
|
||||
|
||||
# `/sbin/setuser www-data` runs the given command as the user `www-data`.
|
||||
cd /srv/webvirtcloud
|
||||
exec /sbin/setuser www-data /srv/webvirtcloud/venv/bin/python /srv/webvirtcloud/console/novncd >> /var/log/novncd.log 2>&1
|
||||
RUNAS=`which setuser`
|
||||
[ -z $RUNAS ] && RUNAS="`which sudo` -u"
|
||||
USER=www-data
|
||||
|
||||
DJANGO_PROJECT=/srv/webvirtcloud
|
||||
PYTHON=$DJANGO_PROJECT/venv/bin/python
|
||||
NOVNCD=$DJANGO_PROJECT/console/novncd
|
||||
|
||||
# make novncd debug, verbose
|
||||
#PARAMS="-d -v"
|
||||
|
||||
LOG=/var/log/novncd.log
|
||||
|
||||
cd $DJANGO_PROJECT
|
||||
exec $RUNAS $USER $PYTHON $NOVNCD $PARAMS >> $LOG 2>&1
|
||||
|
||||
Reference in New Issue
Block a user