vnc gencert

This commit is contained in:
Devaev Maxim
2021-02-15 04:16:03 +03:00
parent c2df0c3871
commit 0442ec3264
2 changed files with 22 additions and 6 deletions

View File

@@ -1,7 +1,7 @@
post_install() {
post_upgrade
echo "==> Generating KVMD certificate ..."
echo "==> Generating KVMD-Nginx certificate ..."
kvmd-gencert --do-the-thing
}
@@ -19,6 +19,16 @@ post_upgrade() {
chown kvmd /var/lib/kvmd/msd || true
if [ ! -d /etc/kvmd/vnc/ssl ]; then
echo "==> Generating KVMD-VNC certificate ..."
kvmd-gencert --do-the-thing --vnc
fi
chown root:root /etc/kvmd/vnc/ssl
chown root:root /etc/kvmd/nginx/ssl
chmod 755 /etc/kvmd/vnc/ssl
chmod 755 /etc/kvmd/nginx/ssl
echo "==> Patching configs ..."
[ ! -f /boot/config.txt ] || sed -i -e 's/^dtoverlay=pi3-disable-bt$/dtoverlay=disable-bt/g' /boot/config.txt
[ ! -f /boot/config.txt ] || sed -i -e 's/^dtoverlay=dwc2$/dtoverlay=dwc2,dr_mode=peripheral/g' /boot/config.txt