我使用 docker-compose 运行 selenoid,我无法为浏览器设置主机表,因为从 selenoid 开始的浏览器中似乎忽略了“hosts”属性。我无法打开 http://myfrontend 页面,因为它无法解析主机名。
A 具有以下browsers.json
配置:
{
"chrome": {
"default": "latest",
"versions": {
"latest": {
"image": "selenoid/vnc_chrome:94.0",
"port": "4444",
"tmpfs": {"/tmp":"size=512m"},
"env" : [ "DRIVER_ARGS=--disable-web-security --ignore-certificate-errors --verbose" ],
"hosts": [
"myfrontend:172.20.176.10"
]
},
"94.0": {
"image": "selenoid/vnc_chrome:94.0",
"port": "4444",
"tmpfs": {"/tmp":"size=512m"},
"env" : [ "DRIVER_ARGS=--disable-web-security --ignore-certificate-errors --verbose" ],
"hosts": [
"myfrontend:172.20.176.10"
]
}
}
}
}