9610fc66d30faea534b1476d8f245b07b0e7fe06
Switches authenticate SSH via RADIUS (aaa authentication login ssh radius local), which is separate from the local admin account used for the HTTPS GUI and baked into generated configs. Web Access Control (HTTPS enable/disable and Disable Telnet) was reusing that local admin credential (or per-switch NocoDB creds) for its SSH connection, which is the wrong credential pair. Adds a dedicated SSH Credentials (RADIUS) section in Settings and a getSshCredentials() helper that Web Access Control uses exclusively, plus an upfront error toast if those fields are left blank. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CLfUJoQTaUePx1m1d2v2j9
Switch Config Manager
Web-based tool for writing, saving, and pushing configuration files to network switches. Pulls switch inventory from NocoDB and provides a browser UI for editing and deploying configs.
Features
- Lists active switches from NocoDB (filterable by department)
- Config editor — write or paste switch configuration in the browser
- Save configs to disk as
hostname.conffiles - Push configs to switches via SSH (Paramiko)
- Web access shortcut — open the switch management UI directly from the app
Quick Start
1. Configure
Copy config.example.py to config.py and fill in your values:
cp config.example.py config.py
nano config.py
NOCODB_URL = "http://your-nocodb-host:8080"
NOCODB_TOKEN = "your-api-token"
NOCODB_BASE_ID = "your-base-id"
NOCODB_TABLE_ID = "your-table-id"
CONFIGS_DIR = "/configs"
2. Build and run
docker compose up -d --build
The app runs on port 8003 by default.
3. Open the UI
http://your-host-ip:8003
NocoDB Requirements
The NocoDB table must have at minimum:
| Column | Description |
|---|---|
Hostname |
Switch hostname (used as filename) |
Active |
Must be YES for the switch to appear |
Dept |
Department code — used for filtering |
Project Structure
switch-config-manager/
├── app.py # Flask API + SSH push logic
├── config.py # Your local config (not committed)
├── config.example.py # Config template
├── requirements.txt # Python dependencies
├── Dockerfile
├── docker-compose.yml
├── templates/
│ └── index.html # Web UI
└── configs/ # Saved .conf files (created at runtime)
Saved Configs
Config files are saved to the configs/ directory as hostname.conf.
The directory is bind-mounted from the host so files persist across container restarts.
Description
Web-based tool for writing, saving, and pushing configuration files to network switches. NocoDB inventory, browser config editor.
Languages
HTML
88.6%
Python
11%
Dockerfile
0.4%