novncで上のコントロールバーを消す
echo "<style>#noVNC_control_bar { display: none; }</style>" \
>> /usr/share/novnc/vnc.html
echo "<style>#noVNC_status_bar { display: none; }</style>" \
>> /usr/share/novnc/vnc_lite.html
i3, firefox
- firefox
- Control + Num
- Workspace
- Alt + Num
- Fullscreen
- Alt + F
起動
docker run -p 6080:6080 -v /dev/shm:/dev/shm -it tukiyo3/novnc
-
http://localhost:6080/
- user1 : password1
- => nginx/htpasswd にて指定
- url
もしくは VNCサーバーに直接接続
docker run -p 127.0.0.1:5900:5900 -v /dev/shm:/dev/shm -it tukiyo3/novnc
ローカルのファイルを起動時に表示する方法
docker run -it -d \
--restart=always \
-p 127.0.0.1:5900:5900 \
-e URL=file:///home/docker/index.html \
-v /dev/shm:/dev/shm \
-v $(pwd)/index.html:/home/docker/index.html \
tukiyo3/novnc
vncviewer localhost
docker-compose
docker-compose.yml
novnc:
image: tukiyo3/novnc
restart: always
links:
- nginx
ports:
- "127.0.0.1:5900:5900"
volumes:
- /dev/shm:/dev/shm
environment:
- URL=http://nginx/index.html
nginx:
image: nginx
restart: always
volumes:
- ./index.html:/usr/share/nginx/html/index.html
- ./index.html を編集した後はnginxコンテナをリスタート
restart.sh
docker-compose stop nginx
docker-compose rm -f nginx
docker-compose up -d nginx