Selenium is a browser automation tool. This particular repository only covers Selenium setup for the Ruby programming language.
To continue further development with this tool, read the official Selenium documentation.
Unfortunately, Selenium itself doesn't support username:password
authentication for HTTP/HTTPs
proxies; therefore, you'll need to have your IP whitelisted.
You can do that by following the guidelines listed here.
- Once you have all the required prerequisites ready, create your project folder:
mkdir selenium_ruby
cd selenium_ruby
- When the project directory is set up, you can now download one of the example scripts for proxy setup with Selenium:
Firefox
curl https://raw.githubusercontent.com/Smartproxy/Selenium/master/ruby/firefox/example.rb > example.rb
Chrome
curl https://raw.githubusercontent.com/Smartproxy/Selenium/master/ruby/chrome/example.rb > example.rb
- Your project folder should now be populated with the example.rb file.
To configure the endpoint you would like to use, change the example endpoint within the punctuation marks ('') here:
You can test the script by running the ruby example.rb
command while in your project folder.
A browser window will appear with the targeted website, and a proxy IP should be visible in the console output:
Email - [email protected]
Live chat 24/7