Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
98 changes: 77 additions & 21 deletions docs.feldera.com/docs/interface/cli.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';

# Command line tool (fda)

`fda` is a command line utility for interacting with the Feldera Manager's REST API.
Expand All @@ -6,7 +9,10 @@ It allows you to create, manage, and monitor pipelines. It also features an inte

## Installation

### Quick Install (Linux)
### Quick Install

<Tabs groupId="os">
<TabItem value="linux" label="Linux">

```bash
curl -fsSL https://feldera.com/install-fda | bash
Expand All @@ -19,24 +25,73 @@ curl -fsSL https://feldera.com/install-fda | bash

Requires glibc >= 2.39 (Ubuntu 24.04+, Debian 13+, Fedora 40+, RHEL 10+).

</TabItem>
<TabItem value="windows" label="Windows">

```powershell
powershell -ExecutionPolicy Bypass -NoProfile -c "irm https://feldera.com/install-fda.ps1 | iex"
```

| Supported platforms |
|---|
| windows-x86_64 |
| windows-arm64 (via emulation) |

Requires Windows 10 or later with PowerShell 5.1+.
Installs `fda.exe` to `%USERPROFILE%\.feldera\bin` and adds it to user's `PATH`.

:::note
Corporate environments may block `irm | iex` via network or execution policy restrictions.
In that case, download the zip directly from the
[GitHub releases page](https://github.com/feldera/feldera/releases) and extract `fda.exe` manually.
:::

</TabItem>
</Tabs>

### Installing a Specific Version

Since `fda` is a single binary, you can update or install older versions by re-running the installer script.

To install a specific version, pass the release git tag to the install script:

<Tabs groupId="os">
<TabItem value="linux" label="Linux">

```bash
curl -fsSL https://feldera.com/install-fda | FDA_VERSION=v0.247.0 bash
curl -fsSL https://feldera.com/install-fda | FDA_VERSION=v0.270.0 bash
```

</TabItem>
<TabItem value="windows" label="Windows">

```powershell
powershell -c "$env:FDA_VERSION='v0.270.0'; irm https://feldera.com/install-fda.ps1 | iex"
```

</TabItem>
</Tabs>

To install to a custom directory:

<Tabs groupId="os">
<TabItem value="linux" label="Linux">

```bash
curl -fsSL https://feldera.com/install-fda | FDA_VERSION=v0.247.0 FELDERA_INSTALL=/opt/feldera bash
curl -fsSL https://feldera.com/install-fda | FDA_VERSION=v0.270.0 FELDERA_INSTALL=/opt/feldera bash
```

### Using Cargo (Windows, MacOS)
</TabItem>
<TabItem value="windows" label="Windows">

```powershell
powershell -c "$env:FELDERA_INSTALL='C:\tools\feldera'; irm https://feldera.com/install-fda.ps1 | iex"
```

</TabItem>
</Tabs>

### Using Cargo (macOS, other platforms)

To install `fda` with Cargo, you need a working Rust environment. You can install Rust by following
the instructions on the [Rust website](https://www.rust-lang.org/tools/install).
Expand Down Expand Up @@ -66,36 +121,37 @@ cargo install --path .
Once the `fda` binary is installed, you can enable shell command completion for `fda`
by adding the following line to your shell init script.

* Bash
<Tabs groupId="os">
<TabItem value="linux" label="Linux">

```bash
# Bash
echo "source <(COMPLETE=bash fda)" >> ~/.bashrc
```

* Elvish

```bash
# Elvish
echo "eval (COMPLETE=elvish fda)" >> ~/.elvish/rc.elv
```

* Fish

```bash
# Fish
echo "source (COMPLETE=fish fda | psub)" >> ~/.config/fish/config.fish
```

* Powershell

```bash
echo "COMPLETE=powershell fda | Invoke-Expression" >> $PROFILE
# Zsh
echo "source <(COMPLETE=zsh fda)" >> ~/.zshrc
```

* Zsh
</TabItem>
<TabItem value="windows" label="Windows">

```bash
echo "source <(COMPLETE=zsh fda)" >> ~/.zshrc
```powershell
# Powershell
mkdir -Force (Split-Path $PROFILE)
'$env:COMPLETE="powershell"; (fda | Out-String) | Invoke-Expression; Remove-Item Env:\COMPLETE -ErrorAction SilentlyContinue' >> $PROFILE
# To activate autocomplete without restarting the terminal:
. $PROFILE
```

</TabItem>
</Tabs>

## Connecting & Authentication

To connect to the Feldera manager, you need to provide the URL of the manager. You can either provide the URL as an
Expand Down
2 changes: 1 addition & 1 deletion docs.feldera.com/static/install-fda
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Feldera fda CLI installer
# Usage:
# curl -fsSL https://feldera.com/install-fda | bash
# curl -fsSL https://feldera.com/install-fda | FDA_VERSION=v0.247.0 bash
# curl -fsSL https://feldera.com/install-fda | FDA_VERSION=v0.270.0 bash
# curl -fsSL https://feldera.com/install-fda | FELDERA_INSTALL=/opt/feldera bash

set -eu
Expand Down
63 changes: 63 additions & 0 deletions docs.feldera.com/static/install-fda.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
# Feldera fda CLI installer for Windows
# Usage:
# irm https://feldera.com/install-fda.ps1 | iex
# $env:FDA_VERSION="v0.270.0"; irm https://feldera.com/install-fda.ps1 | iex
# $env:FELDERA_INSTALL="C:\tools\feldera"; irm https://feldera.com/install-fda.ps1 | iex

$ErrorActionPreference = 'Stop'

$FelderaInstall = if ($env:FELDERA_INSTALL) { $env:FELDERA_INSTALL } else { "$env:USERPROFILE\.feldera" }
$BinDir = "$FelderaInstall\bin"

# AddressWidth is OS bitness, not CPU arch: blocks 32-bit Windows only.
# arm64 passes and gets the x86_64 binary, which runs via Windows emulation.
$Arch = (Get-CimInstance Win32_Processor).AddressWidth
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: AddressWidth returns 32 or 64 based on OS bitness, not CPU architecture. It correctly blocks 32-bit Windows, but arm64 Windows will also pass this check (both report 64). Since only x86_64-pc-windows-msvc is shipped right now that is fine — just worth a comment: # Note: detects 32-bit OS; arm64 will pass.

if ($Arch -ne 64) {
Write-Error "Unsupported OS: only 64-bit Windows is supported."
exit 1
}
$Target = "x86_64-pc-windows-msvc"

if ($env:FDA_VERSION) {
$Version = $env:FDA_VERSION
$DownloadUrl = "https://github.com/feldera/feldera/releases/download/$Version/fda-$Target.zip"
Write-Host "Installing fda $Version"
} else {
$DownloadUrl = "https://github.com/feldera/feldera/releases/latest/download/fda-$Target.zip"
Write-Host "Installing fda (latest)"
}

$TmpDir = [System.IO.Path]::GetTempPath() + [System.Guid]::NewGuid().ToString()
New-Item -ItemType Directory -Path $TmpDir | Out-Null

try {
$TmpZip = "$TmpDir\fda.zip"

Write-Host "Downloading from $DownloadUrl"
Invoke-WebRequest -Uri $DownloadUrl -OutFile $TmpZip -UseBasicParsing

Write-Host "Extracting fda binary"
Expand-Archive -Path $TmpZip -DestinationPath $TmpDir -Force

New-Item -ItemType Directory -Force -Path $BinDir | Out-Null
Move-Item -Force "$TmpDir\fda.exe" "$BinDir\fda.exe"

Write-Host "Installed fda to $BinDir\fda.exe"
} finally {
Remove-Item -Recurse -Force $TmpDir -ErrorAction SilentlyContinue
}

# Add to PATH (user scope) if not already present
$UserPath = [Environment]::GetEnvironmentVariable('PATH', 'User')
if ($UserPath -notlike "*$BinDir*") {
[Environment]::SetEnvironmentVariable('PATH', "$BinDir;$UserPath", 'User')
Write-Host "Added $BinDir to PATH (user). Restart your shell for it to take effect."
}

Write-Host ""
Write-Host "fda was installed successfully!"
& "$BinDir\fda.exe" --version 2>$null

Write-Host ""
Write-Host "To enable shell completions, see:"
Write-Host " https://docs.feldera.com/docs/interface/cli#optional-shell-completion"
Loading