UNPKG

2.09 kBMarkdownView Raw
1<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3
4- [Command line interface](#command-line-interface)
5
6<!-- END doctoc generated TOC please keep comment here to allow auto update -->
7
8# Command line interface
9
10```shell
11# simple, use defaults and latest selenium
12selenium-standalone install
13selenium-standalone start
14
15# install defaults, but silently
16selenium-standalone install --silent
17
18# specify selenium args, everything after -- is for selenium
19selenium-standalone start -- -debug
20
21# choose selenium version
22selenium-standalone install --version=3.141.59 --baseURL=https://selenium-release.storage.googleapis.com
23
24# choose chrome driver version
25selenium-standalone install --drivers.chrome.version=87.0.4280.20 --drivers.chrome.baseURL=https://chromedriver.storage.googleapis.com
26
27# choose ie driver architecture
28selenium-standalone start --drivers.ie.arch=ia32 --drivers.ie.baseURL=https://selenium-release.storage.googleapis.com
29
30# install a single driver within the default list (chrome, ie, edge, firefox, chromiumedge)
31selenium-standalone install --singleDriverInstall=chrome
32
33# specify hub and nodes to setup your own selenium grid
34selenium-standalone start -- -role hub
35selenium-standalone start -- -role node -hub http://localhost:4444/grid/register
36selenium-standalone start -- -role node -hub http://localhost:4444/grid/register -port 5556
37
38# If you have a complex configuration with numerous options or if you want to keep a clear configuration changes history,
39# you can specify the options in a configuration file :
40selenium-standalone install --config=/path/to/config.json
41selenium-standalone start --config=./config/seleniumConfig.js
42
43```
44
45Config file can be a JSON file or a [module file](https://nodejs.org/api/modules.html#modules_file_modules) that exports options as an object:
46
47```js
48module.exports = {
49 drivers: {
50 chrome: {
51 version: '87.0.4280.20',
52 arch: process.arch,
53 baseURL: 'https://chromedriver.storage.googleapis.com'
54 },
55 },
56}
57```