novnc: use installed package files as default for `--web`

This allows novnc to run without manually supplying the location of
`vnc.html` in the Nix store or assembled environment.

+28
+6
pkgs/applications/networking/novnc/default.nix
··· 11 11 sha256 = "sha256-Z+bks7kcwj+Z3uf/t0u25DnGOM60QhSH6uuoIi59jqU="; 12 12 }; 13 13 14 + patches = [ ./fix-paths.patch ]; 15 + 16 + postPatch = '' 17 + substituteAllInPlace utils/novnc_proxy 18 + ''; 19 + 14 20 installPhase = '' 15 21 runHook preInstall 16 22
+22
pkgs/applications/networking/novnc/fix-paths.patch
··· 1 + diff --git a/utils/novnc_proxy b/utils/novnc_proxy 2 + index 0900f7e..a931763 100755 3 + --- a/utils/novnc_proxy 4 + +++ b/utils/novnc_proxy 5 + @@ -22,7 +22,7 @@ usage() { 6 + echo " Default: self.pem" 7 + echo " --key KEY Path to key file, when not combined with cert" 8 + echo " --web WEB Path to web files (e.g. vnc.html)" 9 + - echo " Default: ./" 10 + + echo " Default: @out@/share/webapps/novnc" 11 + echo " --ssl-only Disable non-https connections." 12 + echo " " 13 + echo " --record FILE Record traffic to FILE.session.js" 14 + @@ -44,7 +44,7 @@ PORT="6080" 15 + VNC_DEST="localhost:5900" 16 + CERT="" 17 + KEY="" 18 + -WEB="" 19 + +WEB="@out@/share/webapps/novnc" 20 + proxy_pid="" 21 + SSLONLY="" 22 + RECORD_ARG=""