Main purpose: Use selenium in non-internet private network with R code (Ubuntu 20.04).
Steps: Install Java, install Selenium Server 4.7.2, install Chrome (specific version), Download and use chromeDriver (same version as Chrome), Download and used desire R package (RSelenium) and start coding.
library("RSelenium")
rd <- rsDriver()
rd$open()
Problem: When I call open function I face this error
checking Selenium Server versions:
BEGIN: PREDOWNLOAD
Error in open.connection(con, "rb") :
Could not resolve host: www.googleapis.com
I do some R&D and find Selenium need to download some relevant driver files! Our server are in private network and there is not any proxy for internet at all. So regardless of I use of R on any other languages, can I use Selenium in non-internet private network? If yes which files should I download offline and where should I copy them?
Thanks in advance
2
Answers
For people who wants to use Selenium in private non internet network: As @bingbongtelecom mention rsDrive() manage to download some drives as chromeDriver, Phantomjs, geckodriver and etc to use them. You should download them in other network and copy them in your private network. After that use 'check = False' option to stop checking driver and download process Regards
I think the issue here is that rsDriver creates both the server and the client. As such it includes a wrapper for the function
wdman::selenium()
that is meant to download and manage the drivers needed. I would look into one of the two options: 1) usingrsDriver()
as the package manager and let it download the drivers for you or 2) usingremoteDriver()
on its own (which will not install drivers) to connect to your Selenium Server instead.In the description for rsDriver: