Installation and setup
cpln: command not found
cpln: command not found
cpln.Solutions:-
Verify the installation:
- bash/zsh
- PowerShell
- Command Prompt
-
Check if the binary is on your PATH:
- macOS/Linux
- PowerShell
- Command Prompt
Ensure/usr/local/bin(or your installation directory) is included. -
Reinstall the CLI:
- npm
- Homebrew
- Binary
- Restart your terminal after installation.
Permission denied when installing
Permission denied when installing
npm install -g fails with EACCES permission errors.Solution (recommended): Install Node through a version manager such as nvm, fnm, or Volta. These install Node and its global package directory inside your home folder, so global installs never need sudo and you avoid the permission problem entirely.Legacy: custom prefix without sudo (only if you are NOT using nvm/fnm/Volta)
Legacy: custom prefix without sudo (only if you are NOT using nvm/fnm/Volta)
sudo (not recommended) or configure a custom npm prefix:~/.bashrc, ~/.zshrc, etc.):npm config delete prefix, then remove the export PATH=~/.npm-global/bin:$PATH line from your shell profile. Otherwise the two prefixes will conflict./usr/local/bin:~/bin to your PATH in ~/.bashrc or ~/.zshrc:The CLI lingers after uninstall, or npm targets the wrong location
The CLI lingers after uninstall, or npm targets the wrong location
npm uninstall -g @controlplane/cliprintsup to date(orremoved 0 packages), yetcplnstill runs.npm update -g @controlplane/clireports success butcpln --versiondoesn’t change.- After installing,
cpln: command not foundin a new terminal even though the install succeeded.
~/.npm-global prefix. cpln is a #!/usr/bin/env node script, so it runs under whichever node is first on your PATH, and npm -g reads/writes the prefix of the specific npm you invoke. When those disagree, npm manages one location while cpln actually lives in another — so uninstall and update appear to do nothing.Step 1 — See what you actually have. Run every line; mismatches are the diagnosis:npm config get prefix does not contain the same directory as the resolved cpln path, that is exactly why uninstall/update is a no-op — npm is pointed at the wrong prefix.Step 2 — Remove every stale copy. Uninstall from each prefix that has it, then delete any leftover symlink directly:node you want must be first on PATH before you install, so the install lands where you’ll run it:cpln disappears or reverts version after switching Node (nvm/fnm)
cpln disappears or reverts version after switching Node (nvm/fnm)
cpln worked, then vanished or reverted to an old version after running nvm use, nvm install, or opening a new shell.Cause: Version managers keep a separate global package set per Node version. Installing @controlplane/cli under Node 20 does not make it available under Node 22, and switching versions switches which cpln (if any) is on PATH.Solutions:-
Install the CLI under the Node version you actually use, then pin that version as the default so new shells use it:
-
When upgrading Node, carry your global packages forward:
-
Verify after switching:
A version manager is installed but Homebrew's Node keeps winning
A version manager is installed but Homebrew's Node keeps winning
which node still points at /opt/homebrew/bin/node (or /usr/local/bin/node), so your version manager’s Node — and the cpln installed under it — is ignored.Cause: PATH order. Your shell startup file loads the version manager, but a later line re-prepends Homebrew’s bin to PATH (for example export PATH="/opt/homebrew/bin:$PATH", or Homebrew’s shellenv), so Homebrew’s node ends up ahead of the version manager’s.Solution: Make the version manager activate last in your ~/.zshrc / ~/.bashrc, after any line that prepends Homebrew. With nvm, the robust form is to activate the default version and push its bin to the front of PATH at the end of the file:brew uninstall node (check first that no other Homebrew formula depends on it).Authentication
Authentication failed or 403
Authentication failed or 403
-
Check for typos in the org name:
Verify the
orgvalue is correct. A 403 often means you’re trying to access an org that doesn’t exist or that you don’t have access to. -
Re-authenticate:
-
Check which profile is marked as active with a star
*: -
Verify the token is valid:
-
For service accounts, regenerate the key:
Update your profile with the new token:Make sure the service account is assigned to a group that has the necessary permissions to access and manage resources (e.g. the
superusersgroup).When using--token, always include--gvcto preserve or set your default GVC context.
Login opens the wrong browser
Login opens the wrong browser
cpln login opens a browser you don’t use.Solutions:- Copy the URL from the terminal and paste it into your preferred browser.
- Change your system’s default browser (OS-specific).
- Use a service account token instead of interactive login. See Authentication.
Login doesn't work in WSL2
Login doesn't work in WSL2
cpln login opens a localhost URL that doesn’t work in your Windows browser.Cause: The localhost URL points to the WSL2 instance, not Windows.Solution: Install a browser in WSL2 (requires WSLg):cpln login, copy the localhost URL from the terminal, and paste it into your WSL2 Chrome.Alternative: Use browser-less login with a service account token.Wrong organization or GVC context
Wrong organization or GVC context
-
Check your active profile:
-
Override for a single command:
-
Update your profile defaults:
-
Use a different profile:
-
Set environment variables:
Connectivity and network
TLS certificate errors
TLS certificate errors
- Verify your system’s certificate trust store is up to date.
- Check if you’re behind a corporate proxy or firewall that intercepts TLS.
-
As a temporary workaround (not recommended for production):
- Contact your network administrator to add Control Plane’s certificate to your trust store.
Connection timeout or network errors
Connection timeout or network errors
- Check your internet connection.
-
Verify you can reach the Control Plane API:
- Check if you’re behind a proxy.
Output and display
Output is truncated or incomplete
Output is truncated or incomplete
-
Use JSON or YAML output for complete data:
-
Increase the max results:
-
Use
json-slimoryaml-slimfor cleaner structured output:
Color codes in logs or files
Color codes in logs or files
-
Disable color:
-
Color is automatically disabled when stdout is not a terminal. Redirect to a file:
Commands and operations
Command not found or unknown flag
Command not found or unknown flag
-
Verify you’re using the correct command syntax:
-
Check your CLI version:
-
Update to the latest version:
- npm
- Homebrew
- Binary
Debugging
Enable verbose or debug output to troubleshoot issues:Getting help
If you can’t resolve the issue:- Email us at support@controlplane.com
- Reach out on Slack through the support channel