CentOS7

デスクトップ環境 : VNCクライアント : noVNC インストール

ローカルホストで起動している VNC サーバーをプロキシして、クライアントコンピューターから Web ブラウザ経由で接続できるようにします。

必要なパッケージのインストール、および SSL 証明書の作成をしておきます。

# EPEL からインストール
[root@localhost ~]# yum --enablerepo=epel -y install novnc python-websockify numpy
[root@localhost ~]# cd /etc/pki/tls/certs
[root@localhost certs]# openssl req -x509 -nodes -newkey rsa:2048 -keyout /etc/pki/tls/certs/novnc.pem -out /etc/pki/tls/certs/novnc.pem -days 365
Generating a 2048 bit RSA private key
..........................................+++
..........................................+++
writing new private key to '/etc/pki/tls/certs/novnc.pem'
-----
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----

Country Name (2 letter code) [AU]:JP
# 国

State or Province Name (full name) [Some-State]:Tokyo
# 地域(県)

Locality Name (eg, city) []:Hiroshima
# 都市

Organization Name (eg, company) [Internet Widgits Pty Ltd]:Server World
# 組織名

Organizational Unit Name (eg, section) []:IT Solution
# 組織の部門名

Common Name (eg, YOUR name) []:hoge.com
# サーバーのFQDN

Email Address []:xxx@hoge.com
# 管理者アドレス

こちらのを参考に、VNC サーバーを起動しておきます。

当例では、「cent」ユーザーがポート「5901」で VNC サーバーを起動しているとします。

VNC 起動ユーザーで Websockify を起動し、localhost:5901 をポート 6080 でプロキシします。

[hoge@localhost ~]$ websockify -D --web=/usr/share/novnc/ --cert=/etc/pki/tls/certs/novnc.pem 6080 localhost:5901
WebSocket server settings:
- Listen on :6080
- Flash security policy server
- Web server. Web root: /usr/share/novnc
- SSL/TLS support
- Backgrounding (daemon)

任意のクライアントで Web ブラウザを起動し、「https://(サーバーのホスト名またはIPアドレス):6080/」にアクセスすると、以下のように noVNC の画面が表示されます。 VNC パスワードでログイン可能です。

01.png

接続できました。Web ブラウザ上で CentOS の操作ができます。

02.png


添付ファイル: file02.png 190件 [詳細] file01.png 110件 [詳細]

トップ   編集 凍結 差分 履歴 添付 複製 名前変更 リロード   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS
Last-modified: 2018-09-06 (木) 15:34:16