Size: a a a

Aerokube Support

2020 September 08

АА

Александр Андряшин... in Aerokube Support
sessionTimeout is not a part of goog:chromeOptions, it should be provided as selenoid:options
источник

K

Kavya in Aerokube Support
Александр Андряшин
sessionTimeout is not a part of goog:chromeOptions, it should be provided as selenoid:options
I tried to pass it through Selenoidoptions, now i ended up having selenoidoptions not being recognized by the container. Logs below:2020-09-08T13:06:15.696330717Z Waiting xvfb...
2020-09-08T13:06:15.855674884Z Starting ChromeDriver 2.44.609551 (5d576e9a44fe4c5b6a07e568f1ebc753f1214634) on port 4444
2020-09-08T13:06:15.855702884Z All remote connections are allowed. Use a whitelist instead!
2020-09-08T13:06:15.882934747Z
2020-09-08T13:06:15.882962147Z  --- x11vnc loop: 1 ---
2020-09-08T13:06:15.882966847Z
2020-09-08T13:06:15.910424410Z [1599570375.910][INFO]: [cb93b33f1db691bcd5a8381f46f655ec] COMMAND InitSession {
2020-09-08T13:06:15.910444210Z    "capabilities": {
2020-09-08T13:06:15.910448710Z       "firstMatch": [ {
2020-09-08T13:06:15.910452310Z          "acceptInsecureCerts": true,
2020-09-08T13:06:15.910455810Z          "browserName": "chrome",
2020-09-08T13:06:15.910459310Z          "goog:chromeOptions": {
2020-09-08T13:06:15.910462810Z             "excludeSwitches": [ "enable-automation" ],
2020-09-08T13:06:15.910466310Z             "prefs": {
2020-09-08T13:06:15.910469710Z                "download.default_directory": "/home/selenium/Downloads",
2020-09-08T13:06:15.910473310Z                "download.directory_upgrade": true,
2020-09-08T13:06:15.910476810Z                "download.prompt_for_download": false,
2020-09-08T13:06:15.910480210Z                "plugins.always_open_pdf_externally": true,
2020-09-08T13:06:15.910483610Z                "plugins.plugins_disabled": "Chrome PDF Viewer",
2020-09-08T13:06:15.910487010Z                "profile.default_content_settings.popups": 0,
2020-09-08T13:06:15.910490410Z                "safebrowsing.enabled": false
2020-09-08T13:06:15.910493810Z             },
2020-09-08T13:06:15.910497010Z             "selenoid:options": {
2020-09-08T13:06:15.910500410Z                "enableLog": true,
2020-09-08T13:06:15.910503810Z                "logName": "myfile.log",
2020-09-08T13:06:15.910507210Z                "sessionTimeout": "3m"
2020-09-08T13:06:15.910510510Z             },
2020-09-08T13:06:15.910513710Z             "useAutomationExtension": false
2020-09-08T13:06:15.910517110Z          }
2020-09-08T13:06:15.910520310Z       } ]
2020-09-08T13:06:15.910523410Z    },
2020-09-08T13:06:15.910526610Z    "desiredCapabilities": {
2020-09-08T13:06:15.910529910Z       "acceptInsecureCerts": true,
2020-09-08T13:06:15.910533310Z       "acceptSslCerts": true,
2020-09-08T13:06:15.910536611Z       "browserName": "chrome",
2020-09-08T13:06:15.910540111Z       "enableLog": true,
2020-09-08T13:06:15.910543411Z       "enableVNC": true,
2020-09-08T13:06:15.910546711Z       "goog:chromeOptions": {
2020-09-08T13:06:15.910550011Z          "excludeSwitches": [ "enable-automation" ],
2020-09-08T13:06:15.910566111Z          "prefs": {
2020-09-08T13:06:15.910606311Z             "download.default_directory": "/home/selenium/Downloads",
2020-09-08T13:06:15.910610311Z             "download.directory_upgrade": true,
2020-09-08T13:06:15.910613711Z             "download.prompt_for_download": false,
2020-09-08T13:06:15.910617011Z             "plugins.always_open_pdf_externally": true,
2020-09-08T13:06:15.910620411Z             "plugins.plugins_disabled": "Chrome PDF Viewer",
2020-09-08T13:06:15.910623911Z             "profile.default_content_settings.popups": 0,
2020-09-08T13:06:15.910689611Z             "safebrowsing.enabled": false
2020-09-08T13:06:15.910696011Z          },
2020-09-08T13:06:15.910699211Z          "selenoid:options": {
2020-09-08T13:06:15.910702511Z             "enableLog": true,
2020-09-08T13:06:15.910705811Z             "logName": "myfile.log",
2020-09-08T13:06:15.910709111Z             "sessionTimeout": "3m"
2020-09-08T13:06:15.910712611Z          },
2020-09-08T13:06:15.910715711Z          "useAutomationExtension": false
2020-09-08T13:06:15.910720811Z       },
2020-09-08T13:06:15.910724111Z       "version": "70.0"
2020-09-08T13:06:15.910727511Z    }
2020-09-08T13:06:15.910730711Z }
2020-09-08T13:06:15.912506715Z [1599570375.912][INFO]: [cb93b33f1db691bcd5a8381f46f655ec] RESPONSE InitSess
источник

K

Kavya in Aerokube Support
Александр Андряшин
sessionTimeout is not a part of goog:chromeOptions, it should be provided as selenoid:options
ion ERROR invalid argument: cannot parse capability: goog:chromeOptions
2020-09-08T13:06:15.912521015Z from invalid argument: unrecognized chrome option: selenoid:options
2020-09-08T13:06:15.913073016Z [1599570375.913][DEBUG]: Log type 'driver' lost 1 entries on destruction
2020-09-08T13:06:16.384219802Z  --- x11vnc loop: waiting for: 43
2020-09-08T13:06:16.384275002Z
2020-09-08T13:06:16.453751262Z PORT=5900
источник

АА

Александр Андряшин... in Aerokube Support
selenoid:options should be on the same level as goog:chromeOptions and not nested...
источник

IK

Ivan Krutov in Aerokube Support
DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.setCapability("browserName", "chrome");
capabilities.setCapability("browserVersion", "85.0");
capabilities.setCapability("selenoid:options", Map.<String, Object>of(
   "enableVNC", true,
   "enableVideo", true
));

java 9 example
источник

K

Kavya in Aerokube Support
Ivan Krutov
DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.setCapability("browserName", "chrome");
capabilities.setCapability("browserVersion", "85.0");
capabilities.setCapability("selenoid:options", Map.<String, Object>of(
   "enableVNC", true,
   "enableVideo", true
));

java 9 example
Am using c#.. am finding for an equivalent method for setcapability in c#
источник

IK

Ivan Krutov in Aerokube Support
Kavya
Am using c#.. am finding for an equivalent method for setcapability in c#
same stuff, but use c# dictionary instead of map
источник

IK

Ivan Krutov in Aerokube Support
and in C# method is called SetAdditionalCapability()
источник

IK

Ivan Krutov in Aerokube Support
and requires third argument set to true
источник

K

Kavya in Aerokube Support
Ivan Krutov
same stuff, but use c# dictionary instead of map
I have used dictionary but c# has no set capability method.. I used AddAditionalcapability method which is throwing the exception
источник

K

Kavya in Aerokube Support
Ivan Krutov
and requires third argument set to true
I had missed to set the this argument to true..It works fine now .. Thank u
источник
2020 September 09

MT

Martins Tararujs in Aerokube Support
Hey guys,

Perhaps somebody could help me to figure out how to properly configure one thing as something is not exactly working for me.

So I'm having a setup with automated tests which are planned to be used against selenoid and they currently are using webdriver devtools service. Basically there is a browser setup and whenever devtools as service is used, it tries to connect to some random debugging port as far as i understand. Whenever selenoid is not running, it brings up 3 chrome instances and using properly and test is being executed. Whenever selenoid is up, then there is a refused connection to 127.0.0.1:{random_debuggin_port}.

So it's a bit confusing for me how to make it exactly work with webdriver so that later those functions like browser.cdp('Network', 'emulateNetworkConditions' ..) could still work. Does anybody have some experience with it and could help on this topic?
источник

IK

Ivan Krutov in Aerokube Support
Martins Tararujs
Hey guys,

Perhaps somebody could help me to figure out how to properly configure one thing as something is not exactly working for me.

So I'm having a setup with automated tests which are planned to be used against selenoid and they currently are using webdriver devtools service. Basically there is a browser setup and whenever devtools as service is used, it tries to connect to some random debugging port as far as i understand. Whenever selenoid is not running, it brings up 3 chrome instances and using properly and test is being executed. Whenever selenoid is up, then there is a refused connection to 127.0.0.1:{random_debuggin_port}.

So it's a bit confusing for me how to make it exactly work with webdriver so that later those functions like browser.cdp('Network', 'emulateNetworkConditions' ..) could still work. Does anybody have some experience with it and could help on this topic?
In Selenoid devtools websocket is always available while Chrome is running and connection should be made to Selenoid host snd port
источник

IK

Ivan Krutov in Aerokube Support
No need to read random port from http devtools API
источник

MT

Martins Tararujs in Aerokube Support
Actually devtools service looks like is doingthat by itself and devtools service is the one providing those cdp functions to easily operate with netwrok and other things if I understood correctly how does it work
источник

BB

Boris Becker in Aerokube Support
Добрый день. Как можно узнавать о выходе новой  версии докера selenoid/chrome и selenoid/firefox для очередной версии браузеров?
источник

🛠А

🛠 Александр Аверьяно... in Aerokube Support
Привет - кто-нибудь настраивал реверс-прокси для стека Selenoid + UI, у меня возникли проблемы с настройкой - ни логи, ни VNC недоступно, тесты тоже не проходят

selenoid-ui_1    | 2020/09/09 07:53:34 Client added. 2 registered clients
selenoid_1       | 2020/09/09 10:53:39 [-] [NEW_REQUEST] [unknown] [100.127.4.6]
selenoid_1       | 2020/09/09 10:53:39 [-] [NEW_REQUEST_ACCEPTED] [unknown] [100.127.4.6]
selenoid_1       | 2020/09/09 10:53:39 [5] [LOCATING_SERVICE] [chrome] [85.0]
selenoid_1       | 2020/09/09 10:53:39 [5] [USING_DOCKER] [chrome] [85.0]
selenoid_1       | 2020/09/09 10:53:39 [5] [CREATING_CONTAINER] [selenoid/chrome]
selenoid_1       | 2020/09/09 10:53:39 [5] [STARTING_CONTAINER] [selenoid/chrome] [71d83e985e5301076eaacc1f2cdaf8ce557134da78240d21e6fad69bfa12faf0]
selenoid_1       | 2020/09/09 10:53:40 [5] [CONTAINER_STARTED] [selenoid/chrome] [71d83e985e5301076eaacc1f2cdaf8ce557134da78240d21e6fad69bfa12faf0] [0.29s]
selenoid_1       | 2020/09/09 10:53:40 [5] [SERVICE_STARTED] [selenoid/chrome] [71d83e985e5301076eaacc1f2cdaf8ce557134da78240d21e6fad69bfa12faf0] [0.25s]
selenoid_1       | 2020/09/09 10:53:40 [5] [PROXY_TO] [71d83e985e5301076eaacc1f2cdaf8ce557134da78240d21e6fad69bfa12faf0] [http://100.127.4.7:4444/]
selenoid_1       | 2020/09/09 10:53:40 [5] [SESSION_ATTEMPTED] [http://100.127.4.7:4444/] [1]
selenoid_1       | 2020/09/09 10:53:40 [5] [SESSION_CREATED] [dee91cc6e1227026c2073a4e9a5e4c5a] [1] [0.94s]
reverse-proxy_1  | 100.127.4.1 - - [09/Sep/2020:07:53:40 +0000] "POST /wd/hub/session HTTP/1.1" 200 680 "http://selenoid-prod-ui.soc.bi.zone/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36"
selenoid-ui_1    | 2020/09/09 07:53:57 [WS_PROXY] [/ws/logs/dee91cc6e1227026c2073a4e9a5e4c5a] [ws://selenoid:4444/logs/dee91cc6e1227026c2073a4e9a5e4c5a]
reverse-proxy_1  | 100.127.4.1 - - [09/Sep/2020:07:53:57 +0000] "GET /ws/logs/dee91cc6e1227026c2073a4e9a5e4c5a HTTP/1.1" 403 10 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36"
selenoid_1       | 2020/09/09 10:53:57 [11] [CONTAINER_LOGS] [71d83e985e5301076eaacc1f2cdaf8ce557134da78240d21e6fad69bfa12faf0]
selenoid-ui_1    | 2020/09/09 07:53:57 websocketproxy: couldn't upgrade websocket: request origin not allowed by Upgrader.CheckOrigin
selenoid-ui_1    | 2020/09/09 07:53:57 [WS_PROXY] [/logs/dee91cc6e1227026c2073a4e9a5e4c5a] [CLOSED]
selenoid_1       | 2020/09/09 10:53:57 [11] [CONTAINER_LOGS_DISCONNECTED] [dee91cc6e1227026c2073a4e9a5e4c5a]
selenoid-ui_1    | 2020/09/09 07:53:57 [WS_PROXY] [/ws/vnc/dee91cc6e1227026c2073a4e9a5e4c5a] [ws://selenoid:4444/vnc/dee91cc6e1227026c2073a4e9a5e4c5a]
selenoid_1       | 2020/09/09 10:53:57 [12] [VNC_ENABLED] [dee91cc6e1227026c2073a4e9a5e4c5a]
reverse-proxy_1  | 100.127.4.1 - - [09/Sep/2020:07:53:57 +0000] "GET /ws/vnc/dee91cc6e1227026c2073a4e9a5e4c5a HTTP/1.1" 403 10 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36"
selenoid-ui_1    | 2020/09/09 07:53:57 websocketproxy: couldn't upgrade websocket: request origin not allowed by Upgrader.CheckOrigin
selenoid-ui_1    | 2020/09/09 07:53:57 [WS_PROXY] [/vnc/dee91cc6e1227026c2073a4e9a5e4c5a] [CLOSED]
selenoid_1       | 2020/09/09 10:53:57 [12] [VNC_CLIENT_DISCONNECTED] [dee91cc6e1227026c2073a4e9a5e4c5a]
selenoid_1       | 2020/09/09 10:53:57 [12] [VNC_SESSION_CLOSED] [dee91cc6e1227026c2073a4e9a5e4c5a]
источник

IK

Ivan Krutov in Aerokube Support
Martins Tararujs
Actually devtools service looks like is doingthat by itself and devtools service is the one providing those cdp functions to easily operate with netwrok and other things if I understood correctly how does it work
I know but it is complicated to implement the same approach with remote browser access
источник

IK

Ivan Krutov in Aerokube Support
🛠 Александр Аверьянов
Привет - кто-нибудь настраивал реверс-прокси для стека Selenoid + UI, у меня возникли проблемы с настройкой - ни логи, ни VNC недоступно, тесты тоже не проходят

selenoid-ui_1    | 2020/09/09 07:53:34 Client added. 2 registered clients
selenoid_1       | 2020/09/09 10:53:39 [-] [NEW_REQUEST] [unknown] [100.127.4.6]
selenoid_1       | 2020/09/09 10:53:39 [-] [NEW_REQUEST_ACCEPTED] [unknown] [100.127.4.6]
selenoid_1       | 2020/09/09 10:53:39 [5] [LOCATING_SERVICE] [chrome] [85.0]
selenoid_1       | 2020/09/09 10:53:39 [5] [USING_DOCKER] [chrome] [85.0]
selenoid_1       | 2020/09/09 10:53:39 [5] [CREATING_CONTAINER] [selenoid/chrome]
selenoid_1       | 2020/09/09 10:53:39 [5] [STARTING_CONTAINER] [selenoid/chrome] [71d83e985e5301076eaacc1f2cdaf8ce557134da78240d21e6fad69bfa12faf0]
selenoid_1       | 2020/09/09 10:53:40 [5] [CONTAINER_STARTED] [selenoid/chrome] [71d83e985e5301076eaacc1f2cdaf8ce557134da78240d21e6fad69bfa12faf0] [0.29s]
selenoid_1       | 2020/09/09 10:53:40 [5] [SERVICE_STARTED] [selenoid/chrome] [71d83e985e5301076eaacc1f2cdaf8ce557134da78240d21e6fad69bfa12faf0] [0.25s]
selenoid_1       | 2020/09/09 10:53:40 [5] [PROXY_TO] [71d83e985e5301076eaacc1f2cdaf8ce557134da78240d21e6fad69bfa12faf0] [http://100.127.4.7:4444/]
selenoid_1       | 2020/09/09 10:53:40 [5] [SESSION_ATTEMPTED] [http://100.127.4.7:4444/] [1]
selenoid_1       | 2020/09/09 10:53:40 [5] [SESSION_CREATED] [dee91cc6e1227026c2073a4e9a5e4c5a] [1] [0.94s]
reverse-proxy_1  | 100.127.4.1 - - [09/Sep/2020:07:53:40 +0000] "POST /wd/hub/session HTTP/1.1" 200 680 "http://selenoid-prod-ui.soc.bi.zone/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36"
selenoid-ui_1    | 2020/09/09 07:53:57 [WS_PROXY] [/ws/logs/dee91cc6e1227026c2073a4e9a5e4c5a] [ws://selenoid:4444/logs/dee91cc6e1227026c2073a4e9a5e4c5a]
reverse-proxy_1  | 100.127.4.1 - - [09/Sep/2020:07:53:57 +0000] "GET /ws/logs/dee91cc6e1227026c2073a4e9a5e4c5a HTTP/1.1" 403 10 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36"
selenoid_1       | 2020/09/09 10:53:57 [11] [CONTAINER_LOGS] [71d83e985e5301076eaacc1f2cdaf8ce557134da78240d21e6fad69bfa12faf0]
selenoid-ui_1    | 2020/09/09 07:53:57 websocketproxy: couldn't upgrade websocket: request origin not allowed by Upgrader.CheckOrigin
selenoid-ui_1    | 2020/09/09 07:53:57 [WS_PROXY] [/logs/dee91cc6e1227026c2073a4e9a5e4c5a] [CLOSED]
selenoid_1       | 2020/09/09 10:53:57 [11] [CONTAINER_LOGS_DISCONNECTED] [dee91cc6e1227026c2073a4e9a5e4c5a]
selenoid-ui_1    | 2020/09/09 07:53:57 [WS_PROXY] [/ws/vnc/dee91cc6e1227026c2073a4e9a5e4c5a] [ws://selenoid:4444/vnc/dee91cc6e1227026c2073a4e9a5e4c5a]
selenoid_1       | 2020/09/09 10:53:57 [12] [VNC_ENABLED] [dee91cc6e1227026c2073a4e9a5e4c5a]
reverse-proxy_1  | 100.127.4.1 - - [09/Sep/2020:07:53:57 +0000] "GET /ws/vnc/dee91cc6e1227026c2073a4e9a5e4c5a HTTP/1.1" 403 10 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36"
selenoid-ui_1    | 2020/09/09 07:53:57 websocketproxy: couldn't upgrade websocket: request origin not allowed by Upgrader.CheckOrigin
selenoid-ui_1    | 2020/09/09 07:53:57 [WS_PROXY] [/vnc/dee91cc6e1227026c2073a4e9a5e4c5a] [CLOSED]
selenoid_1       | 2020/09/09 10:53:57 [12] [VNC_CLIENT_DISCONNECTED] [dee91cc6e1227026c2073a4e9a5e4c5a]
selenoid_1       | 2020/09/09 10:53:57 [12] [VNC_SESSION_CLOSED] [dee91cc6e1227026c2073a4e9a5e4c5a]
нужно добавить для ui флаг -allowed-origin *
источник

🛠А

🛠 Александр Аверьяно... in Aerokube Support
спасибо - сейчас попробую
источник