1

在此处输入图像描述

根据上面的屏幕截图,我正在断开 VNC 连接。这是使用 docker 托管在远程服务器上的。这是“Docker 实现中的 Docker”

这是我的 docker-compose 文件

version: "3"
networks:
  selenoid:
    external:
      name: selenoid
services:
  selenoid:
    networks:
        selenoid: null
    image: "aerokube/selenoid:latest-release"
    restart: always
    ports:
        - "4444:4444"
    volumes:
        - /var/run/docker.sock:/var/run/docker.sock
        - "$PWD/selenoidconfig:/etc/selenoid/:ro"
        - $HOME/Projects/videos:/opt/selenoid/video
        - "$PWD/logs:/opt/selenoid/logs"
    environment:
        - OVERRIDE_VIDEO_OUTPUT_DIR=$HOME/Projects/videos
    command: ["-video-output-dir", "/opt/selenoid/video", "-log-output-dir", "/opt/selenoid/logs","-container-network", "selenoid","-timeout","8h","-service-startup-timeout","10m","-session-attempt-timeout","10m", ]
  selenoid-ui:
      networks:
          selenoid: null
      image: "aerokube/selenoid-ui"
      restart: always
      depends_on:
          - selenoid
      ports:
          - "8081:8080"
      command: ["--selenoid-uri", "http://selenoid:4444"]

我不能看直播视频。但是当我单击视频链接时,我可以观看旧视频。我可以看到这个控制台错误 - >连接时失败:连接关闭(代码:1000)rfb.js:668

我设法从 --> docker-compose logs --follow 得到以下错误

[VNC ERROR] [dial tcp 172.18.0.5:5900: connect: connection refused

我也设法捕获了一些错误输出。我可以看到以下错误

95439231.695][INFO]: Waiting for pending navigations...
[1595439231.695][DEBUG]: DevTools WebSocket Command: Runtime.evaluate (id=355) 907E8B9EDE154FC01AEB8BC2D449BDD9 {
"expression": "1"
}
[1595439231.695][DEBUG]: DevTools WebSocket Response: Runtime.evaluate (id=355) 907E8B9EDE154FC01AEB8BC2D449BDD9 {
"result": {
"description": "1",
"type": "number",
"value": 1
}
}
[1595439231.695][INFO]: Done waiting for pending navigations. Status: ok
[1595439231.695][INFO]: [5193d46ce8e3cb8ce787f4e283b3e674] RESPONSE ClickElement
--- x11vnc loop: waiting for: 413

error opening logfile: /home/selenium/x11vnc.log
open: Permission denied

--- x11vnc loop: sleeping 500 ms ---

--- x11vnc loop: 8 ---

[1595439232.699][INFO]: [5193d46ce8e3cb8ce787f4e283b3e674] COMMAND ExecuteAsyncScript {
"args": [ "" ],
"script": "try { return (function anonymous(\n) {\nfunction getNg1Hooks(selector, injectorPlease) {\n function tryEl(el) {\n try {\n if (!injectorPlease && angular.getTestability) {\n var $$testabil..."
}
[1595439232.699][DEBUG]: DevTools WebSocket Event: DOM.childNodeCountUpdated 907E8B9EDE154FC01AEB8BC2D449BDD9 {
"childNodeCount": 15,
"nodeId": 23
}
[1595439232.699][DEBUG]: DevTools WebSocket Event: DOM.attributeModified 907E8B9EDE154FC01AEB8BC2D449BDD9 {
"name": "class",
"nodeId": 23,
"value": " ng-scope "
}
4

1 回答 1

1

我删除了图像。然后拉为普通用户。我必须以 root 用户身份提取 selenoid/vinc:chrome 图像。现在它可以工作了

于 2020-07-23T12:30:39.670 回答