WithDocumentation Index
Fetch the complete documentation index at: https://docs.mogenius.com/llms.txt
Use this file to discover all available pages before exploring further.
mocli, you can manage your mogenius clusters, browse Kubernetes resources, stream logs, and set up port-forwarding — all from your terminal.
The CLI includes an interactive Terminal UI (TUI) that provides k9s-style navigation without requiring a local kubeconfig. Authentication is handled through the mogenius platform, giving you secure access to any connected cluster from anywhere.
Installation
Mac, Linux
Use homebrew to installmocli:
On Linux with a headless machine,
mocli requires a browser for the initial login. After the first login, your session persists locally.Windows
Getting Started
You need a mogenius account to usemocli. If you don’t have one yet, sign up here.
Login
Run the following command to authenticate. Your browser will open automatically to complete the login:Terminal UI
Launch the interactive TUI to browse and manage your resources:Navigation
The TUI follows a hierarchical navigation pattern: Organization → Cluster → Namespace → Resources| Key | Action |
|---|---|
| Arrow keys | Move up/down |
Enter | Select / drill down |
Esc | Go back |
q | Quit |
/ | Filter list |
: | Command mode (switch resource types) |
Browsing Resources
Once you select a namespace, you’ll see a list of Pods by default. Use command mode (:) to switch between resource types:
:podsor:po— Pods:deploymentsor:deploy— Deployments:servicesor:svc— Services:statefulsetsor:sts— StatefulSets:daemonsetsor:ds— DaemonSets:jobs— Jobs:cronjobsor:cj— CronJobs:configmapsor:cm— ConfigMaps:secrets— Secrets:ingressesor:ing— Ingresses
Viewing Logs
Select a Pod and pressEnter to view its logs in real-time. If the Pod has multiple containers, you’ll be prompted to select one.
| Key | Action |
|---|---|
PgUp / PgDn | Scroll through logs |
s | Toggle autoscroll |
w | Toggle word wrap |
Esc | Return to resource list |
Port Forwarding
From the logs view or resource list, presst to create a port-forward tunnel to the selected Pod. Enter the port mapping (e.g., 8080:80) and the tunnel will be established.
Active tunnels persist while the TUI is running. Press Esc from the port-forward view to return to browsing while keeping tunnels open.
CLI Commands
In addition to the TUI,mocli provides direct CLI commands:
Connecting a Cluster
You can use the CLI to install the mogenius operator on your Kubernetes cluster:- In the mogenius UI, add a new cluster
- Run the connect command:
- Select the cluster from the list that matches your current kube context
- Confirm to deploy the operator
mocli cluster list or through the mogenius UI.