This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
vps:vps4th2nd_10 [2019/06/16 15:16] 127.0.0.1 external edit |
vps:vps4th2nd_10 [2019/10/20 20:32] hoge@hoge [WebSockify 設定] |
||
---|---|---|---|
Line 1: | Line 1: | ||
====== ブラウザでの desktop 接続 ====== | ====== ブラウザでの desktop 接続 ====== | ||
- | prisoner desktop にブラウザで接続する。 | + | prisoner desktop にブラウザで接続する。\\ |
+ | {{:vps:novnc.png}} | ||
===== desktop 設定 ===== | ===== desktop 設定 ===== | ||
==== pkg ==== | ==== pkg ==== | ||
Line 7: | Line 7: | ||
* xdm | * xdm | ||
* xsm | * xsm | ||
- | |||
==== xdm ==== | ==== xdm ==== | ||
prisner desktop 起動時に xdm を起動する。 | prisner desktop 起動時に xdm を起動する。 | ||
Line 38: | Line 37: | ||
* #any host can get a login window | * #any host can get a login window | ||
</code> | </code> | ||
+ | * /usr/local/etc/X11/xdm/xdm-config 編集<code> | ||
+ | !DisplayManager.requestPort: 0 | ||
+ | </code> | ||
Line 75: | Line 76: | ||
</code> | </code> | ||
* /usr/local/libexec/novnc/utils/websockify/run 修正<code> | * /usr/local/libexec/novnc/utils/websockify/run 修正<code> | ||
- | #!/usr/bin/env python3.6 (python を python3.6 に修正) | + | python3.6 -m websockify $@ (python を python3.6 に修正) |
</code> | </code> | ||
- | ==== novnc 設定 ==== | + | ==== noVNC 設定 ==== |
- | novnc 向け設定を行う。 | + | noVNC 向け設定を行う。 |
* /usr/local/etc/rc.d/novnc を作成する。<code> | * /usr/local/etc/rc.d/novnc を作成する。<code> | ||
#!/bin/sh | #!/bin/sh | ||
Line 108: | Line 109: | ||
novnc_remote="192.168.100.2:5901" | novnc_remote="192.168.100.2:5901" | ||
</code> | </code> | ||
+ | * ログインページ作成を作成する。 | ||
+ | * /usr/local/libexec/novnc/vnc.html を削除もしくは *.html 以外に変更。 | ||
+ | * /usr/local/libexec/novnc/vnc_auto.html を推測しにくい名前に変更。 | ||
==== apache 設定 ==== | ==== apache 設定 ==== | ||
Line 116: | Line 120: | ||
</code> | </code> | ||
* /usr/local/etc/apache24/extra/httpd-ssl.conf 設定<code> | * /usr/local/etc/apache24/extra/httpd-ssl.conf 設定<code> | ||
+ | SSLCACertificateFile "/usr/local/etc/apache24/ssl.crt/cacert.pem" | ||
+ | |||
ProxyRequests Off | ProxyRequests Off | ||
ProxyPass /websockify ws://localhost:6080/websockify retry=3 | ProxyPass /websockify ws://localhost:6080/websockify retry=3 | ||
Line 127: | Line 133: | ||
Require all granted | Require all granted | ||
</Directory> | </Directory> | ||
+ | <Location /websockify/> | ||
+ | SSLVerifyClient require | ||
+ | </Location> | ||
</code> | </code> | ||
* /websockify へは reverse proxy 設定 | * /websockify へは reverse proxy 設定 | ||
* /usr/local/libexec/novnc へは alias 設定 | * /usr/local/libexec/novnc へは alias 設定 | ||
* <パス> は推測しにくいものにしたほうが良い? | * <パス> は推測しにくいものにしたほうが良い? | ||
+ | * クライアント証明書で保護 | ||