Locking an environment by using the command line

You can lock an environment by using the HCL OneTest™ API command line. This option is useful in situations where Ant is not available.
The syntax to use is as follows::
IntegrationTesterCmd Options lock-environment
Here is an example syntax:
IntegrationTesterCmd --serverUrl "https://<Host name or IP address>:5443/RTCP/" 
--domain <Domain name> --environment <Environment name> 
--username <User name> --duration <Number of minutes> 
--reason <Reason> lock-environment

The following table lists the options that you can use with the IntegrationTesterCmd command for locking an environment.

Table 1. List of available options
Options Description
--serverUrl/-u URL of HCL Quality Server.
--domain/-d Domain name
--environment/-e Environment name.
--username/-l The user name under which to perform the operation (optional).
--reason/-r The reason for locking the environment (optional).
--duration The number of minutes that you expect to keep the environment locked (optional).
--force/-f Attempt to first unlock the environment if another user has the lock (flag).
--securityToken The value of the security token to use for authentication with HCL Quality Server when domain security is enabled (optional). For more information, see Domain level security.

Error codes

For details of any error codes, see Exit codes for Command-line client and Ant client.

Feedback