Installation
The teactl command-line interface (CLI) is your primary tool for interacting with Teabar. This guide covers all installation methods for macOS, Linux, and Windows.
System Requirements
Before installing, ensure your system meets these requirements:
| Requirement | Minimum | Recommended |
|---|---|---|
| Operating System | macOS 10.15+, Linux (glibc 2.17+), Windows 10+ | Latest stable version |
| Architecture | x86_64 or ARM64 | Native architecture |
| Disk Space | 50 MB | 100 MB |
| Internet | Required for installation and operation | Stable broadband |
Additional Requirements
- Shell: bash, zsh, fish, or PowerShell
- Permissions: sudo access for system-wide installation (optional)
- Dependencies: None (statically linked binary)
Quick Install (Recommended)
The fastest way to install teactl on macOS or Linux:
curl -fsSL https://teabar.dev/install.sh | sh What the Script Does
- Detects your system - Identifies OS (macOS/Linux) and architecture (amd64/arm64)
- Downloads the binary - Fetches the latest stable release
- Verifies integrity - Checks SHA256 checksum
- Installs - Places the binary in
/usr/local/binwhen writable (or~/.local/binotherwise) - PATH hint - Prints a one-line PATH export if needed
Install Script Options
# Install specific version
curl -fsSL https://teabar.dev/install.sh | sh -s -- --version v0.0.4
# Install to custom directory
curl -fsSL https://teabar.dev/install.sh | sh -s -- --install-dir ~/.local/bin
# Preview without installing
curl -fsSL https://teabar.dev/install.sh | sh -s -- --dry-run Note
Windows (PowerShell)
Use the PowerShell installer:
iwr https://teabar.dev/install.ps1 -UseBasicParsing | iex Manual Installation
If you prefer to download and install manually, or need to verify the binary yourself:
Step 1: Download
Download the appropriate archive for your platform (these URLs redirect to the artifact store):
- Latest version marker:
https://teabar.dev/downloads/teactl/latest/VERSION - Checksums:
https://teabar.dev/downloads/teactl/<TAG>/SHA256SUMS
| Platform | Architecture | File name |
|---|---|---|
| macOS | Intel (x86_64) | teactl_<TAG>_darwin_amd64.tar.gz |
| macOS | Apple Silicon (ARM64) | teactl_<TAG>_darwin_arm64.tar.gz |
| Linux | x86_64 | teactl_<TAG>_linux_amd64.tar.gz |
| Windows | x86_64 | teactl_<TAG>_windows_amd64.zip |
Example (Linux amd64)
TAG="$(curl -fsSL https://teabar.dev/downloads/teactl/latest/VERSION)"
FILE="teactl_${TAG}_linux_amd64.tar.gz"
curl -fsSLO "https://teabar.dev/downloads/teactl/${TAG}/${FILE}"
curl -fsSLO "https://teabar.dev/downloads/teactl/${TAG}/SHA256SUMS"
sha256sum -c SHA256SUMS
sudo tar -C /usr/local/bin -xzf "${FILE}" teactl
teactl version Step 2: Verify Checksum
Always verify the download integrity:
# For macOS/Linux
sha256sum -c teactl-*.sha256
# Expected output:
# teactl-linux-amd64: OK On macOS without sha256sum:
shasum -a 256 -c teactl-*.sha256 Step 3: Install
# Rename the binary
mv teactl-* teactl
# Make it executable
chmod +x teactl
# Move to a directory in your PATH
sudo mv teactl /usr/local/bin/
# Or install to user directory (no sudo required)
mkdir -p ~/.local/bin
mv teactl ~/.local/bin/ Step 4: Verify PATH
Ensure the installation directory is in your PATH:
# Check if teactl is found
which teactl
# If not found, add to PATH (bash/zsh)
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc
source ~/.bashrc Windows Manual Installation
- Resolve the latest tag:
https://teabar.dev/downloads/teactl/latest/VERSION - Download
teactl_<TAG>_windows_amd64.zipandSHA256SUMS - Verify the checksum
- Extract
teactl.exeand place it in a directory on your PATH
$Tag = (Invoke-WebRequest -UseBasicParsing -Uri "https://teabar.dev/downloads/teactl/latest/VERSION").Content.Trim()
$File = "teactl_${Tag}_windows_amd64.zip"
Invoke-WebRequest -UseBasicParsing -Uri "https://teabar.dev/downloads/teactl/${Tag}/${File}" -OutFile $File
Invoke-WebRequest -UseBasicParsing -Uri "https://teabar.dev/downloads/teactl/${Tag}/SHA256SUMS" -OutFile "SHA256SUMS"
$Expected = (Select-String -Path "SHA256SUMS" -Pattern ([regex]::Escape($File) + "$") | Select-Object -First 1).Line.Split()[0]
$Actual = (Get-FileHash -Algorithm SHA256 -Path $File).Hash
if ($Expected.ToLower() -ne $Actual.ToLower()) { throw "Checksum mismatch" }
Expand-Archive -Path $File -DestinationPath . eactl -Force
# Move . eactl eactl.exe to a folder on PATH Docker
Run teactl in a Docker container without local installation:
docker run --rm -it
-v ~/.teabar:/root/.teabar
teabar/teactl:latest
version Create an Alias
For convenience, add an alias to your shell profile:
# bash/zsh
alias teactl='docker run --rm -it -v ~/.teabar:/root/.teabar teabar/teactl:latest'
# Add to ~/.bashrc or ~/.zshrc for persistence
echo "alias teactl='docker run --rm -it -v ~/.teabar:/root/.teabar teabar/teactl:latest'" >> ~/.bashrc Docker Compose
For CI/CD pipelines, use in docker-compose.yml:
services:
teactl:
image: teabar/teactl:latest
volumes:
- ~/.teabar:/root/.teabar
environment:
- TEABAR_TOKEN=${TEABAR_TOKEN} Verify Installation
After installation, verify everything is working:
teactl version
teactl version -o json {
"version": "dev",
"commit": "unknown",
"buildDate": "unknown",
"goVersion": "go1.x.x",
"os": "windows",
"arch": "amd64"
}
Expected output:
teactl version 1.2.3 Build date: 2024-01-15 Git commit: abc1234def5 Go version: go1.21.5 OS/Arch: darwin/arm64
### Check for Updates
See if a newer version is available:
```bash
teactl version --check Current version: 1.2.3
Latest version: 1.2.4
Update available! Run 'teactl upgrade' or reinstall. Shell Completions
Enable tab completion for faster command entry:
Bash
# System-wide (requires sudo)
sudo teactl completion bash > /etc/bash_completion.d/teactl
# User-only
mkdir -p ~/.local/share/bash-completion/completions
teactl completion bash > ~/.local/share/bash-completion/completions/teactl
# Reload your shell
source ~/.bashrc Zsh
# Add to fpath (Oh My Zsh)
teactl completion zsh > ~/.oh-my-zsh/completions/_teactl
# Or standard zsh
teactl completion zsh > "${fpath[1]}/_teactl"
# Reload completions
autoload -U compinit && compinit Fish
teactl completion fish > ~/.config/fish/completions/teactl.fish PowerShell
# Add to your PowerShell profile
teactl completion powershell >> $PROFILE Configuration
After installation, teactl stores configuration in ~/.teabar/:
~/.teabar/
├── config.yaml # CLI configuration
├── credentials # Authentication tokens
├── envs/ # Environment kubeconfigs
└── cache/ # Cached data Environment Variables
Override configuration with environment variables:
| Variable | Description | Example |
|---|---|---|
TEABAR_CONFIG | Config file path | /etc/teabar/config.yaml |
TEABAR_TOKEN | OIDC token (for CI/CD) | <keycloak-access-token> |
TEABAR_ORGANIZATION | Default organization | my-org |
TEABAR_API_URL | API endpoint (self-hosted) | https://api.teabar.internal |
TEABAR_NO_COLOR | Disable colored output | true |
TEABAR_DEBUG | Enable debug logging | true |
Upgrading
To upgrade, re-run the installer (it will replace the existing binary):
curl -fsSL https://teabar.dev/install.sh | sh Windows (PowerShell):
iwr https://teabar.dev/install.ps1 -UseBasicParsing | iex Uninstalling
Manual Uninstall
# Remove binary
sudo rm /usr/local/bin/teactl
# or
rm ~/.local/bin/teactl
# Remove configuration (optional)
rm -rf ~/.teabar
# Remove shell completions
rm /etc/bash_completion.d/teactl
rm ~/.oh-my-zsh/completions/_teactl Troubleshooting
“command not found: teactl”
The binary isn’t in your PATH:
# Find where it's installed
find ~ -name teactl -type f 2>/dev/null
ls /usr/local/bin/teactl
# Add to PATH
export PATH="$HOME/.local/bin:$PATH" “permission denied”
The binary isn’t executable:
chmod +x $(which teactl) “cannot execute binary file”
Wrong architecture. Check your system:
uname -m
# x86_64 = amd64
# aarch64/arm64 = arm64 Download the correct binary for your architecture.
“certificate verify failed”
Your system’s CA certificates may be outdated:
# macOS
brew install ca-certificates
# Ubuntu/Debian
sudo apt install ca-certificates
sudo update-ca-certificates
# RHEL/CentOS
sudo yum install ca-certificates
sudo update-ca-trust Proxy Issues
If you’re behind a corporate proxy:
export HTTP_PROXY=http://proxy.example.com:8080
export HTTPS_PROXY=http://proxy.example.com:8080
export NO_PROXY=localhost,127.0.0.1
# Then run teactl commands
teactl auth login Next Steps
Now that teactl is installed:
- Quick Start Guide - Deploy your first environment
- Authentication - Configure authentication methods
- CLI Reference - Explore all available commands
- First Training Session - Set up environments for participants
Tip
teactl help to see all available commands, or teactl [command] --help for detailed help on any command.