GithubHelp home page GithubHelp logo

mortzdk / selenium-server Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 0.0 86 KB

A bash script to run a selenium-server instance in "standalone", "node" or "hub" mode with the supported drivers of the platform running the script.

License: MIT License

Shell 97.18% Java 2.82%
selenium selenium-server bash selenium-driver selenium-webdriver internetexplorer firefox chrome opera edge safari macos linux cygwin windows automatic

selenium-server's Introduction

Selenium Server

This repository contains a bash script for starting a selenium node, hub, or standalone server on Linux, MacOS, or Window (Cygwin).

Requirements

The script has a few requirements that are checked, before beginning the execution of the server. These are:

  • arch
  • java
  • wget
  • unzip
  • tar
  • sed
  • jq

Furthermore on Windows, Powershell must be available, since it is used to figure out which browsers are installed and which version they have.

Configuration

The script supports the following arguments on execution e.g. ./server.sh where '{}' describes the required input, '[]' contains the default value and '()' contains a description of the argument:

  • -i (Shows the information about the arguments available for the server)
  • -d (Enable debug mode)
  • -n {NAME} (The name of the application server)
  • -r [standalone] (Which role the server should have. Valid arguments are 'standalone', 'node', 'hub'.)
  • -h {HUB_ADDRESS} (The address to the hub host)
  • -j {JAR_PATH} [newest-selenium-jar] (The path to a selenium server jar)
  • -a {ADDRESS} [0.0.0.0] (The address for which the server should run)
  • -p {PORT} [4444|5555] (The port that the server should run on)
  • -D {JAVA_ARGS} (Arguments supplied to the JAR)
  • -m {MAX_INSTANCES} (The number of supported simultaneous instances of each of the drivers)
  • -c {CONFIG_PATH} [autogenerated_config] (The path to a selenium config json file)

If no configuration file is specified i.e. -c, the script will generate an appropriate configuration file for the server. Moreover the script will download and use the appropriate versions of the Chrome, Opera, Gecko (Firefox), IE, Safari, and Edge drivers based on which browsers are installed on the system, along with the newest version of the selenium server. Each driver will be available from the 'drivers' folder, and will only be downloaded once.

Logs

If possible each driver will maintain its own log which will be stored in the 'logs' folder. Furthermore the selenium server will also maintain a log.

Known issues

Listed here are the known issue of the released versions:

Version 0.1
  • Multiple versions of browsers can be installed on the OS. There should be a way to setup multiple of the same browser instance. This is not yet possible.
  • The Safari support is not yet implemented
  • The script is not yet tested on MacOS

Notes

Listed ehre are some notes worth reading, when using the script:

  • For Edge version >= 44.17763, the edge driver is no longer downloadable. Instead one should run the following command in the Windows command prompt with administrative rights to enable usage of the driver: DISM.exe /Online /Add-Capability /CapabilityName:Microsoft.WebDriver~~~~0.0.1.0
  • The IE driver follows the selenium versioning meaning that the driver will probably only work for the specific version of the selenium JAR.
  • On Windows (CygWin) the path to the firefox binary must be set using the system environment PATH, which in turn means that only one instance (version) of firefox can be run for each selenium-server.

selenium-server's People

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.