cells-enterprise admin license-stats
./cells-enterprise admin license-stats
Load current license statistics
Synopsis
DESCRIPTION
Query running Cells instance to load license statistics. Without arguments, it will output license statistics
TEMPLATING
Using the --format flag allows you to create your own output using Golang templating. Input data is { ActiveUsers:int MaxUsers:int UsersPercent:int ExpireTime:timestamp ExpireDate:string ExpireIn:seconds } You can for example display a simple percentage using {{.UsersPercent}}% template.
You can use conditions to return an error signal (1) for special cases, by printing the specific ERROR_CODE keyword.
For example:
Return error if users usage is greater than 90% $ ./cells-enterprise admin license-stats --format="{{if gt .UsersPercent 90}}ERROR_CODE{{end}}"
Return error if license will expire in less than 3 days (518400 seconds) $ ./cells-enterprise admin license-stats --format="{{if lt .ExpireIn 518400}}ERROR_CODE{{end}}"
./cells-enterprise admin license-stats [flags]
Options
-f, --format string Use golang template to compute your own output
-h, --help help for license-stats
-r, --refresh Force users computation to be refresh, this can take some time
Options inherited from parent commands
--broker string Pub/sub service for events between services (currently nats only) (default "memory")
--nats_address string NATS server address (default ":4222")
--nats_cluster_address string NATS server cluster address
--nats_cluster_routes string NATS server cluster routes
--nats_monitor_port int Expose nats monitoring endpoints on a given port (default 8222)
--nats_streaming_cluster_bootstrap NATS streaming bootstrap cluster
--nats_streaming_cluster_id string NATS streaming cluster ID (default "cells")
--nats_streaming_cluster_node_id string NATS streaming cluster node id
--nats_streaming_cluster_peers string NATS streaming list of cluster peers
--nats_streaming_clustered NATS streaming clustered
--nats_streaming_store string NATS streaming store type (default "MEMORY")
--port_broker int Port used to start a broker discovery service (default 8003)
--port_registry int Port used to start a registry discovery service (default 8000)
--registry string Registry used to manage services (currently nats only) (default "memory")
--transport string Transport protocol for RPC (default "grpc")
SEE ALSO
- ./cells-enterprise admin - Direct Read/Write access to Cells data