The Login CLI command is used to allow a user to authenticate to RegScale. It serves two primary purposes:
- Serves as a "smoke test" to ensure connectivity to RegScale
- Allows for authentication which sets the JSON Web Token (JWT) in the
init.yamlprogrammatically which is good for up to 24 hours
- Login with a user account:
--usernameYour RegScale username, if none provided it will try to get it from the environment variable
--passwordYour RegScale password, if none provided it will try to get it from the environment variable
--domainYour RegScale instance URL, if none is provided it will try to get it from an environment variable
REGSCALE_DOMAIN. Lastly, if there it is not provided, nor is it set up in the environment, it will use the domain saved in
--mfa_tokenThe One Time Password to log in with if your RegScale instance has Multi-Factor Authentication enabled
- Login with a Service Account
--tokenThe service account token from the Admin panel in RegScale
You can set up environment variables of REGSCALE_USER, REGSCALE_PASSWORD and REGSCALE_DOMAIN to skip all prompts and prevent entering a plain text password.
- Ensure the
domainvariable is set in your
init.yamlfile to your RegScale instance's URL (i.e.
- Attempt to login with the command below
- At the prompts, enter your username and password
- If authentication was successful, your
init.yamlwill be updated with a new
- Login with a service token by using the command below
regscale login --token "Bearer eyao13.213asdajhd"
Updated about 1 month ago