This guide provides multiple ways to set up your development environment for the Hyperloop H10 project.
We provide multiple scripts to work across different platforms:
# Make script executable
chmod +x scripts/dev.sh
# Install dependencies and setup
./scripts/dev.sh setup
# Run individual services
./scripts/dev.sh backend # Run backend server
./scripts/dev.sh ethernet # Run ethernet-view
./scripts/dev.sh control # Run control-station
./scripts/dev.sh packet # Run packet-sender
# Run all services in tmux
./scripts/dev.sh all# You may need to allow script execution first:
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
# Install dependencies and setup
.\scripts\dev.ps1 setup
# Run individual services
.\scripts\dev.ps1 backend # Run backend server
.\scripts\dev.ps1 ethernet # Run ethernet-view
.\scripts\dev.ps1 control # Run control-station
.\scripts\dev.ps1 packet # Run packet-sender
# Run all services in separate windows
.\scripts\dev.ps1 allREM Install dependencies and setup
scripts\dev.cmd setup
REM Run individual services
scripts\dev.cmd backend REM Run backend server
scripts\dev.cmd ethernet REM Run ethernet-view
scripts\dev.cmd control REM Run control-station
scripts\dev.cmd packet REM Run packet-sender
REM Run all services in separate windows
scripts\dev.cmd allFor Windows users with Git Bash, WSL, or MSYS2:
# Enhanced cross-platform script with better Windows support
chmod +x scripts/dev-unified.sh
./scripts/dev-unified.sh setup
./scripts/dev-unified.sh all# Run all services
docker-compose -f docker-compose.dev.yml up
# Run specific service
docker-compose -f docker-compose.dev.yml up backend# 1. Build common-front first (required)
cd common-front
npm install
npm run build
# 2. Install frontend dependencies
cd ../ethernet-view
npm install
cd ../control-station
npm install
# 3. Run services
cd backend/cmd && go run . # Terminal 1
cd ethernet-view && npm run dev # Terminal 2
cd control-station && npm run dev # Terminal 3
cd packet-sender && go run . # Terminal 4For developers who prefer Nix for reproducible environments:
# Pure shell with Fish
nix-shell
# Or with your existing shell config
nix-shell -A impureThis provides a fully reproducible development environment with all dependencies.
- PowerShell Script (
dev.ps1) is recommended over Command Prompt (dev.cmd) for better functionality - If you encounter execution policy issues:
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser - The
allcommand opens each service in separate windows instead of using tmux - For Unix-like experience on Windows, use Git Bash, WSL, or MSYS2 with the unified script
- The
allcommand uses tmux for session management (install with your package manager) - If tmux is unavailable, services run in parallel background processes
- Use
Ctrl+Cto stop all services when running in parallel mode
- Use the
dev-unified.shscript for enhanced Windows compatibility - Automatically detects WSL and adjusts behavior accordingly
- Provides better path handling for Windows environments
- Go 1.21+
- Node.js 18+
- npm
- libpcap (for packet capture)
- macOS:
brew install libpcap - Ubuntu:
sudo apt-get install libpcap-dev - Windows: Install WinPcap or Npcap
- macOS:
- Backend: 8080
- Control Station: 5173
- Ethernet View: 5174
./scripts/dev.sh test
# or manually:
cd backend && go test -v ./...make all# Go dependencies
cd backend && go mod tidy
# Node dependencies
cd common-front && npm update
cd control-station && npm update
cd ethernet-view && npm update-
Permission denied on macOS/Linux for packet capture:
sudo setcap cap_net_raw+ep $(which go) -
Common-front not found errors: Make sure to build common-front first:
cd common-front && npm install && npm run build
-
Port already in use: Check and kill processes using the ports:
lsof -i :8080 # backend lsof -i :5173 # control-station lsof -i :5174 # ethernet-view