This reference covers version: latest

Ggr UI is a standalone daemon that automatically collects /status information from multiple Selenoid instances and returns it as a single /status API. When this daemon is running you can use Selenoid UI to see the state of the entire cluster.

1. Getting Started

1.1. Quick Start Guide

  1. Prerequisites:

  2. Start Ggr UI binary or container:

    $ ./ggr-ui -quota-dir /path/to/quota/dir # As a binary
    
    $ docker run -d --name ggr-ui -p 8888:8888 -v /path/to/quota/dir:/etc/grid-router/quota:ro aerokube/ggr-ui:latest-release

    Binaries as usually can be downloaded from releases page.

  3. Now start Selenoid UI and point it to http://localhost:8888. It should start showing sessions running anywhere in Selenium cluster behind Ggr.

    If you are linking Selenoid UI and Ggr UI containers, then URI should be http://<ggr-ui-container-name>:8888, e.g. http://ggr-ui:8888.
  4. You can also use /status API similarly to Selenoid /status API:

    $ curl -s http://localhost:8888/status

1.2. Quota Reloading

To reload quota files just send SIGHUP to process or Docker container:

# kill -HUP <pid>
# docker kill -s HUP <container-id-or-name>
Use only one of these commands depending on whether you have Docker installed.

1.3. CLI Flags

The following flags are supported by ggr-ui command:

  -authenticated-access-only
    	Show statistics about all hosts only when credentials are provided
  -grace-period duration
    	graceful shutdown period (default 5m0s)
  -guests-allowed
    	Allow guest (unauthenticated) users to access the grid
  -guests-quota string
    	Which quota file to use for guests (default "guest")
  -limit int
    	simultaneous http requests (default 10)
  -listen string
    	host and port to listen to (default ":8888")
  -quota-dir string
    	quota directory (default "quota")
  -response-time duration
    	response time limit (default 2s)
  -timeout duration
    	request timeout (default 30s)
  -version
    	Show version and exit

2. Contributing & Development

To build Ggr UI:

  1. Install Golang 1.11 and above.

  2. Close Ggr UI source:

    $ git clone https://github.com/aerokube/ggr-ui.git
  3. Go to project directory:

    $ cd ggr-ui
  4. Build source:

    $ go build

    This will also automatically fetch dependencies.

  5. Run Ggr UI:

    $ ./ggr-ui --help

To build Docker container type:

$ GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build
$ docker build -t ggr-ui:latest .

2.1. Documentation

Locally can be generated with:

$ docker run --rm -v `pwd`/docs/:/documents/      \
    asciidoctor/docker-asciidoctor                \
    asciidoctor -D /documents/output/ index.adoc