Activate ReadyAPI on Headless Machines and CI/CD build runs with SLM

Applies to ReadyAPI 3.41, last modified on September 23, 2022

This page is related to new SmartBear ID-based licenses that we’ve introduced in ReadyAPI 3.8.1.
For information on regular file-based licenses that are also used in version 3.41, see File-Based Licenses.

About

Running ReadyAPI on a headless machine means that it works from the command line. The same happens when you run ReadyAPI and its test runners from a CI/CD build.

To specify the SmartBear licenses to be used for the run, you add certain parameters to the command line. See below for details.

ReadyAPI licenses to which this info applies

The explanation below works for both Fixed User and Floating types of ReadyAPI.
SmartBear ID-based licenses.

The use of SLM licenses in Private Networks is explained here.

Use of ReadyAPI on Virtual Machines and with Docker images requires a floating ReadyAPI license.

Requirements

Activating licenses in Private Networks

If configuring network settings is not possible, you need to convert your online SmartBear licenses to offline ones and activate these offline licenses in your private network. Follow these links for details:

Floating licenses (Floating users, Virtual Machines, Docker Images).

Fixed User licenses (headless use on Physical Machines).

Floating licenses require downloading and installing a special On-Premise License Server.

The computer where you are going to run tests must have access to the internal (on-prem) License Servers.

Before you commence to use ReadyAPI in Headless mode

In order to use ReadyAPI headlessly, you need to export the required license to the on-prem server using the server fingerprint file as outlined here.

You must then assign the correct license to the required user or service account for headless calls to be successful. See License Administrators actions outlinedhere.

Once the license has been assigned to the user account requiring headless access, you can configure your headless commands and implement your test.

Configure and Run the Headless Commands

Functional, Performance, Security, and Virtual Service testrunners

Once the correct license has been assigned to the Test User, you can configure and run Functional, Performance, Security, and Virtual Service testrunners via Command Line. Use the similar parameters to activate the on-prem license:

"C:\Program Files\SmartBear\ReadyAPI-xxx\bin\testrunner.bat" -Uuser@mail.adslm -V<password> -DlicenseApiHost=SLM_License_Server_Address -DlicenseApiPort=SLM_License_Server_Port "-EDefault environment" C:\Project-test.xml

Alternatively, you may use the Get Access Key for the Test User on the on-prem server. You can configure and run Functional, Performance, Security, and Virtual Service testrunners via Command Line. Use the similar parameters to activate the on-prem license, this time adding the Access Key instead of credentials:

"C:\Program Files\SmartBear\ReadyAPI-xxx\bin\testrunner.bat" -K<Access Key> -DlicenseApiHost=SLM_License_Server_Address -DlicenseApiPort=SLM_License_Server_Port "-EDefault environment" C:\Project-test.xml

Docker Image

You can also run Functional, Performance, Security, and Virtual Service testrunners via Docker and with Command Line.

Install Docker on your machine with Install Docker image with SoapUI TestRunner.

Put the project in the preferred folder e.g., "C:\TestDocker\Projects"

Once you have created your ready-api-soapui-testrunner docker image, you must assign the Test or Bundle license to the Test User as outlined here .

Request the Get Access Key for the Test User on the on-prem server. Enter the following command in the console and press Enter:

docker run -v="C:\TestDocker\Projects":/project -e SLM_LICENSE_SERVER="<Address for onprem SLM license server>" -e API_KEY="<API key for floating SLM>" -e COMMAND_LINE="'-EDefault environment' -DlicenseApiHost=SLM_LICENSE_SERVER -DlicenseApiPort=SLM_LICENSE_SERVER_PORT -sTestSuite-Main -cTestCase-Main '/%project%/Project-func-test.xml'" -it smartbear/ready-api-soapui-testrunner:<tag>

These instructions also with Docker image with SoapUI TestRunner with uienv tag.

Note: A floating license is required for use of ReadyAPI on Virtual Machines and Docker. Use of Fixed Offline licenses will cause errors in the console log: “Please contact your administrator to assign a floating license to Docker”.

See Also

ReadyAPI – Licensing in Private Networks

Highlight search results