Ubuntu22.04运行Splash Docker镜像报错,cloud not load the Qt platform xcb in even though it was found

发布时间 2023-09-19 22:59:48作者: wem2017

一、问题描述

Ubuntu 22.04 运行Splash Docker镜像报错,cloud not load the Qt platform xcb in even though it was found
奇怪的地方在于,停止运行,重新执行同样的语句,即恢复正常。本文只做了问题记录,没有深入研究原因。

sudo docker run -it -p 8050:8050 scrapinghub/splash

image

二、可能涉及的版本关系

docker: 24.0.1(查询语句sudo docker --version)
python:3.10.12 (查询语句sudo python --version)
已设置软链接,python指向python3

三、尝试和解决

翻到了几篇文章,刚想重试观察报错时,splash已经运行成功了。浏览器输入0.0.0.0:8050即可正常打开页面。

image

image

image

参考的文章(最终没用上):
https://www.ngui.cc/el/3194721.html?action=onClick
https://www.jb51.net/article/193024.htm