Search
Varnish Controller

vcli login

Log in to your Varnish Controller service and fetch the login token for subsequent use

Synopsis

First-time users of the client should run this command to connect to the apigw to establish an authenticated session, it will save the connection information to the configuration file. The default configuration will be saved to your home directory in “.vcli.yml”.

If username, password is not provided, the command will prompt for user input as needed.

Environment variables can be used for username, password, endpoint and organization: VARNISH_CONTROLLER_CLI_ENDPOINT VARNISH_CONTROLLER_CLI_USERNAME VARNISH_CONTROLLER_CLI_PASSWORD VARNISH_CONTROLLER_CLI_ORGANIZATION

If using self-signed TLS certificates on the API endpoints, the CA certificate can be specified to validate the TLS connection: VARNISH_CONTROLLER_CLI_CA=

It is also possible to login without verifying the TLS cert: VARNISH_CONTROLLER_CLI_INSECURE=true (or –insecure during login)

Password can be provided in clear text as the first line in a file, using environment variable (or –passwordfile flag): VARNISH_CONTROLLER_CLI_PASSWORDFILE=<password_file>

Examples:

vcli login https://localhost:8080 -u admin
vcli login https://localhost:8080 -u username -o organizationName
vcli login https://localhost:8080 --idp=true -o organizationName
vcli login https://localhost:8080 -u admin --insecure
vcli login https://localhost:8080 -u admin --ca=/path/to/ca.pem
vcli login https://localhost:8080 -u admin --passwordfile <password_file>
vcli login [endpoint] [flags]

Options

      --ca string             TLS CA cert for verifying HTTPS connection
  -h, --help                  help for login
      --idp                   Login using 3rd party Identity Provider
      --insecure              Use insecure TLS
  -l, --label string          Label for your session (default "vcli")
  -o, --organization string   Set your organization
      --passwordfile string   Read password from given file
      --proxy string          Use this proxy URL towards the API GW.
  -u, --username string       Set your username

Options inherited from parent commands

  -c, --config string   configuration file for the CLI (default ~/.vcli.yml)
                        Could also be set via VARNISH_CONTROLLER_CLI_CONFIG=/path/to/config.yml
      --csv             Output the response table as CSV format.
  -j, --json            Output the response table as JSON format.

SEE ALSO

  • vcli - Varnish Controller CLI