This reference covers version: 1.8.7.
Configuration manager is a small application used to automatically configure Aerokube products.
1. Quick Start Guide
To start Selenoid:
-
Download the latest release binary from GitHub releases for your platform (linux/darwin/windows).
-
Having the binary launch one command:
On Linux and Mac OS$ ./cm selenoid start --vncRunning this command with
sudocan lead to broken installation. Recommended way is running Selenoid as regular user. On Linux to have permissions to access Docker you may need to add your user todockergroup:$ sudo usermod -aG docker $USEROn Windows> ./cm.exe selenoid start --vnc
|
If you are working behind proxy you should set environment variables
|
2. Configuring Selenoid
This section describes supported ways of automatic Selenoid configuration.
|
To quickly configure and run Selenoid with defaults type:
|
Selenoid can be configured in two ways:
-
Using Docker containers (default)
-
Using standalone binaries (when
--use-driversis added)
To view the list of available commands:
./cm selenoid --help
To launch command:
./cm selenoid <command> [args...]
Supported commands are:
| Command | Meaning |
|---|---|
args |
Print Selenoid command line arguments |
cleanup |
Removes Selenoid traces |
configure |
Creates Selenoid configuration file (implies download) |
download |
Downloads Selenoid binary or container image |
start |
Starts Selenoid process or container (implies download and configure) |
status |
Shows actual configuration status (whether Selenoid is downloaded, configured or running) |
stop |
Stops Selenoid process or container |
update |
Updates Selenoid and configuration to latest version |
To see supported flags for each command append --help:
./cm selenoid start --help
2.1. Example Commands
-
downloadcommand downloads latest or specified Selenoid release as standalone binary or container image:./cm selenoid download --version 1.2.1 --forceThis command does nothing when already downloaded. Use
--forceflag to download again. -
configurecommand in addition to downloading Selenoid also downloads container images or webdriver binaries and generates configuration file:./cm selenoid configure --browsers firefox:>45.0;opera:53.0;android --last-versions 2 --tmpfs 128Use
--browsersto limit browsers to be configured,--tmpfs- to add Tmpfs support,--last-versions- to limit how many last browser versions to download. If you wish to download all available versions - specify--last-versions 0. -
startcommand configures Selenoid and starts it:./cm selenoid startBy default Selenoid data is stored in
~/.aerokube/selenoidbut you can specify another directory using--config-dirflag. To download images with VNC server (to see live browser screen) use--vncflag:./cm selenoid start --vncTo override Selenoid listen port add
--portflag:./cm selenoid start --port 4445To override Selenoid startup arguments sessions add
--argsflag:./cm selenoid start --args "-limit 10"To download images from private registry - log in with
docker logincommand and add--registryflag:docker login my-registry.example.com # Specify user name and password ./cm selenoid start --registry https://my-registry.example.com
2.2. Downloading Only Some Browser Versions
By default CM downloads browser images corresponding to 2 last versions of Firefox, Chrome and Opera. To download concrete browser versions - use --browsers flag as follows:
./cm selenoid start --browsers 'firefox:51.0;firefox:55.0;chrome:66.0'
./cm selenoid start --browsers 'firefox:>51.0,<=55.0;opera' --last-versions 3
./cm selenoid start --browsers 'android:6.0'
2.3. Using Existing Configuration File
In some cases you may want to configure Selenoid to use an existing browsers.json configuration file. This is mainly needed to always use the same browser versions instead of downloading latest versions. To achieve this:
-
Prepare a desired
browsers.jsonconfiguration file -
Launch
cmwith--browsers-jsonflag:./cm selenoid start --browsers-json /path/to/browsers.json
3. Starting Selenoid UI
This section describes supported ways of automatic Selenoid UI startup.
|
To quickly run Selenoid UI type:
|
Selenoid UI configuration algorithm is similar to Selenoid one - it can be started either in Docker container if you have Docker installed or as a standalone binary otherwise. Supported commands are:
| Command | Meaning |
|---|---|
args |
Print Selenoid UI command line arguments |
cleanup |
Removes Selenoid UI traces |
download |
Downloads Selenoid UI binary or container image |
start |
Starts Selenoid UI process or container (implies download) |
status |
Shows actual service status (whether Selenoid is downloaded or running) |
stop |
Stops Selenoid UI process or container |
update |
Updates Selenoid to latest version |
To see supported flags for each command append --help:
$ ./cm selenoid start --help
4. Contributing & Development
To build cm:
|
To build Docker container type:
|