Skip to main content

SSH & Terminal

Built-in web terminal and remote shell access for EdgeFlow

The built-in terminal provides direct command-line access to your EdgeFlow host right from the browser. Execute system commands, check service status, and manage your device without needing a separate SSH client.

Terminal Overview

The terminal emulator runs directly in the EdgeFlow web interface, connecting to the host shell over a WebSocket at /ws/terminal. It behaves like a standard terminal with support for command history, tab completion, and colored output.

Local Shell
Connected
edgeflow@raspberrypi:~ $ systemctl status edgeflow
• edgeflow.service - EdgeFlow IoT Platform
   Active: active (running) since Mon 2026-01-20 10:00:00 UTC
   Memory: 156M
   CPU: 2.3%
edgeflow@raspberrypi:~ $ _
Connected bash ~
🔌

WebSocket Shell

Real interactive shell session via /ws/terminal. Full PTY support with streaming output.

âŦ†ī¸

Command History

Use Up/Down arrow keys to cycle through previously executed commands during the session.

â‡Ĩ

Tab Completion

Intelligent auto-completion for commands and file paths powered by the server shell.

đŸ–Ĩī¸

Cross-Platform

Uses bash on Linux/macOS and cmd.exe on Windows. Auto-detects the host platform.

Accessing the Terminal

There are three ways to open the terminal in EdgeFlow:

1

Debug Panel Tab

Click the "Terminal" tab at the bottom of the Flow Editor to open the terminal in the debug panel.

2

Keyboard Shortcut

Press Ctrl + ` to toggle the terminal panel open or closed from anywhere in the editor.

3

Navigation Menu

Go to Tools > Terminal from the main navigation menu to open the terminal in a full view.

Terminal Features

Command History

Use the Up and Down arrow keys to cycle through previously executed commands. History is maintained for the duration of the session and resets when the WebSocket connection is closed.

Tab Completion

Press Tab to auto-complete commands and file paths. On Linux, the server uses bash compgen for intelligent completion suggestions. Matching completions are shown as inline suggestions that you can accept with the right arrow key.

Built-in Commands

Command Description
clear Clear all terminal output and reset the display
help Show a list of available built-in commands and shortcuts

Working Directory

The terminal tracks your current working directory across commands. Use cd to navigate the file system. The prompt automatically updates to show the current path so you always know where you are.

Output Types

Type Color Description
Input White Commands you type into the terminal
Output Green Standard output from executed commands
Error Red Error messages from stderr
System Blue System notifications and connection status messages

WebSocket Protocol

The terminal communicates with the EdgeFlow server over a WebSocket connection at /ws/terminal. The React TerminalPanel component manages the connection and renders the output. Below is the message protocol used by the terminal.

Client Messages

Messages sent from the browser to the server:

// Execute a command
{ "type": "command", "command": "ls -la" }

// Request tab completion
{ "type": "complete", "command": "sys", "partial": "sys" }

Server Messages

Messages sent from the server back to the browser:

// Command output (may be multiple messages)
{ "type": "output", "output": "total 48\ndrwxr-xr-x 12 ..." }

// Command error
{ "type": "error", "output": "permission denied" }

// Command completed
{ "type": "done", "cwd": "/home/edgeflow", "exitCode": 0 }

// Tab completion results
{ "type": "completion", "suggestions": ["systemctl", "systemd"], "partial": "sys" }

Quick Commands

Common commands you can run directly in the EdgeFlow terminal to inspect and manage your device:

â„šī¸
uname -a

Show kernel and system information

âš™ī¸
systemctl status edgeflow

Check EdgeFlow service status

💾
df -h

Show disk space usage

🧠
free -m

Show memory usage in MB

đŸŒĄī¸
vcgencmd measure_temp

CPU temperature (Raspberry Pi only)

🌐
ip addr

Show network interfaces

📜
journalctl -u edgeflow -f

Follow EdgeFlow logs in real-time

📌
gpio readall

Show GPIO pin states

Terminal Settings

Customize the terminal appearance and behavior from Settings > Terminal:

Setting Options Default
Font Family JetBrains Mono, Fira Code, monospace JetBrains Mono
Font Size 10 – 24 14
Scrollback Buffer 100 – 10,000 lines 1000
Cursor Style Block, Underline, Bar Block
Shell /bin/bash, /bin/sh, cmd.exe Auto-detect

Troubleshooting

🔴 WebSocket Disconnected

Cause: Network interruption or EdgeFlow server restart.

Solution: Refresh the page to re-establish the WebSocket connection. Verify the EdgeFlow service is running.

🟡 Command Timeout

Cause: Commands timeout after 30 seconds if they do not complete.

Solution: For long-running commands, use nohup or screen to run them in the background.

đŸ”ĩ Shell Not Found

Cause: The configured shell binary is not available on the host system.

Solution: Go to Settings > Terminal > Shell and verify the shell path is correct. Install the shell if needed.

âšĢ Permission Denied

Cause: The command requires elevated privileges that the edgeflow user does not have.

Solution: Use sudo for commands that require root access. Ensure the edgeflow user is in the sudoers group.