Add terminal UI and update README
This commit is contained in:
parent
81a01fbad7
commit
5494f255ae
2 changed files with 54 additions and 597 deletions
651
README.md
651
README.md
|
|
@ -1,301 +1,74 @@
|
|||
# ⚙️ update-manager
|
||||
# 🖥️ Update Manager
|
||||
|
||||
Simple CLI tool for checking and managing updates across multiple Linux hosts over SSH.
|
||||
Simple CLI tool to check and manage updates across multiple Ubuntu systems over SSH.
|
||||
|
||||
Built for speed, clarity, and control — no fluff.
|
||||
Built for Lanx environments – lightweight, fast and no unnecessary dependencies.
|
||||
|
||||
---
|
||||
|
||||
## 🚀 Features
|
||||
|
||||
* Check for available updates on all hosts
|
||||
* Run updates remotely via SSH
|
||||
* Simple host configuration file
|
||||
* Interactive terminal UI (whiptail)
|
||||
* Lightweight and dependency-minimal
|
||||
* Check updates on multiple hosts
|
||||
* Run updates remotely over SSH
|
||||
* Simple config files
|
||||
* No agents required
|
||||
* Works with existing SSH setup
|
||||
|
||||
---
|
||||
|
||||
## 📦 Installation (Full Setup)
|
||||
## 🖥️ UI Preview
|
||||
|
||||
### 1. Clone repo
|
||||

|
||||
|
||||
> Lightweight • No dependencies • Works over SSH
|
||||
|
||||
---
|
||||
|
||||
## ⚡ Quick Install (1-minute setup)
|
||||
|
||||
```bash
|
||||
git clone https://github.com/your-repo/update-manager.git
|
||||
git clone https://github.com/YOUR-USER/update-manager.git
|
||||
cd update-manager
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 2. Create install directory
|
||||
|
||||
```bash
|
||||
sudo mkdir -p /opt/update-manager
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 3. Copy files
|
||||
|
||||
```bash
|
||||
sudo cp update-manager.sh /opt/update-manager/
|
||||
sudo cp update-manager-ui.sh /opt/update-manager/ 2>/dev/null
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 4. Make executable
|
||||
|
||||
```bash
|
||||
sudo chmod +x /opt/update-manager/update-manager.sh
|
||||
sudo chmod +x /opt/update-manager/update-manager-ui.sh 2>/dev/null
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 5. Create symlinks
|
||||
|
||||
```bash
|
||||
sudo ln -sf /opt/update-manager/update-manager.sh /usr/local/bin/update-manager
|
||||
sudo ln -sf /opt/update-manager/update-manager-ui.sh /usr/local/bin/update-manager-ui 2>/dev/null
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 6. Install dependencies
|
||||
|
||||
```bash
|
||||
sudo apt update && sudo apt install -y whiptail openssh-client
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 7. First run (creates config)
|
||||
|
||||
```bash
|
||||
update-manager check
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## ⚡ Quick Start (1 minute)
|
||||
|
||||
### Edit hosts file
|
||||
|
||||
```bash
|
||||
nano /opt/update-manager/hosts.conf
|
||||
```
|
||||
|
||||
Example:
|
||||
|
||||
```txt
|
||||
# name ip user
|
||||
lanx-ai 172.16.5.135 ed
|
||||
lanx-www 172.16.5.140 ed
|
||||
lanx-modoboa 172.16.5.130 ed
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### Run check
|
||||
|
||||
```bash
|
||||
update-manager check
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## 🧠 Notes
|
||||
|
||||
* Hosts file is created automatically on first run
|
||||
* Lines starting with `#` are ignored
|
||||
* Empty lines are ignored
|
||||
* Requires passwordless SSH access
|
||||
|
||||
---
|
||||
|
||||
## 🔐 SSH Setup (Required)
|
||||
|
||||
Generate SSH key (if needed):
|
||||
|
||||
```bash
|
||||
ssh-keygen
|
||||
```
|
||||
|
||||
Copy key to hosts:
|
||||
|
||||
```bash
|
||||
ssh-copy-id user@host
|
||||
```
|
||||
|
||||
Test access:
|
||||
|
||||
```bash
|
||||
ssh user@host
|
||||
```
|
||||
|
||||
✔ No password prompt = ready
|
||||
|
||||
---
|
||||
|
||||
## 🖥️ Terminal UI
|
||||
|
||||
Interactive menu for managing hosts.
|
||||
|
||||
### Start UI
|
||||
|
||||
```bash
|
||||
update-manager-ui
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### UI Features
|
||||
|
||||
* Check all hosts
|
||||
* View hosts file
|
||||
* Edit hosts file
|
||||
* Add host
|
||||
* Remove host
|
||||
|
||||
---
|
||||
|
||||
## 📁 File Structure
|
||||
|
||||
```txt
|
||||
/opt/update-manager/
|
||||
├── update-manager.sh
|
||||
├── update-manager-ui.sh
|
||||
├── hosts.conf
|
||||
└── update-manager.conf
|
||||
sudo ln -s /opt/update-manager/update-manager.sh /usr/local/bin/update-manager
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## ⚙️ Configuration
|
||||
|
||||
Default config:
|
||||
### 1. Copy config files
|
||||
|
||||
```bash
|
||||
/etc/update-manager.conf
|
||||
cp update-manager.conf.example update-manager.conf
|
||||
cp hosts.conf.example hosts.conf
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 2. Edit hosts
|
||||
|
||||
```bash
|
||||
nano hosts.conf
|
||||
```
|
||||
|
||||
Example:
|
||||
|
||||
```bash
|
||||
HOSTS_FILE="/opt/update-manager/hosts.conf"
|
||||
SSH_OPTIONS="-o BatchMode=yes -o ConnectTimeout=5"
|
||||
lanx-ai 172.16.5.135 ed
|
||||
lanx-www 172.16.5.140 ed
|
||||
lanx-mail 172.16.5.130 ed
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## 🔧 Commands
|
||||
## ▶️ Usage
|
||||
|
||||
```bash
|
||||
update-manager check # Check all hosts
|
||||
update-manager update # Run updates on all hosts
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## 💡 Philosophy
|
||||
|
||||
* Keep it simple
|
||||
* Keep it transparent
|
||||
* No hidden magic
|
||||
* Pure SSH control
|
||||
|
||||
---
|
||||
|
||||
## 🧱 Future Ideas
|
||||
|
||||
* Email reports (cron)
|
||||
* Ntfy messages
|
||||
* Optional web UI
|
||||
|
||||
---
|
||||
|
||||
## ❤️ Built for Lanx
|
||||
|
||||
Designed for clean infrastructure, not enterprise chaos.
|
||||
|
||||
Developed by Ed & NodeFox
|
||||
|
||||
---
|
||||
|
||||
# ⚙️ update-manager
|
||||
|
||||
Simple CLI tool for checking and managing updates across multiple Linux hosts over SSH.
|
||||
|
||||
Built for speed, clarity, and control — no fluff.
|
||||
|
||||
---
|
||||
|
||||
## 🚀 Features
|
||||
|
||||
* Check for available updates on all hosts
|
||||
* Run updates remotely via SSH
|
||||
* Simple host configuration file
|
||||
* Interactive terminal UI (whiptail)
|
||||
* Lightweight and dependency-minimal
|
||||
|
||||
---
|
||||
|
||||
## 📦 Installation (Full Setup)
|
||||
|
||||
### 1. Clone repo
|
||||
|
||||
```bash
|
||||
git clone https://github.com/your-repo/update-manager.git
|
||||
cd update-manager
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 2. Create install directory
|
||||
|
||||
```bash
|
||||
sudo mkdir -p /opt/update-manager
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 3. Copy files
|
||||
|
||||
```bash
|
||||
sudo cp update-manager.sh /opt/update-manager/
|
||||
sudo cp update-manager-ui.sh /opt/update-manager/ 2>/dev/null
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 4. Make executable
|
||||
|
||||
```bash
|
||||
sudo chmod +x /opt/update-manager/update-manager.sh
|
||||
sudo chmod +x /opt/update-manager/update-manager-ui.sh 2>/dev/null
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 5. Create symlinks
|
||||
|
||||
```bash
|
||||
sudo ln -sf /opt/update-manager/update-manager.sh /usr/local/bin/update-manager
|
||||
sudo ln -sf /opt/update-manager/update-manager-ui.sh /usr/local/bin/update-manager-ui 2>/dev/null
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 6. Install dependencies
|
||||
|
||||
```bash
|
||||
sudo apt update && sudo apt install -y whiptail openssh-client
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 7. First run (creates config)
|
||||
### Check updates
|
||||
|
||||
```bash
|
||||
update-manager check
|
||||
|
|
@ -303,367 +76,51 @@ update-manager check
|
|||
|
||||
---
|
||||
|
||||
## ⚡ Quick Start (1 minute)
|
||||
|
||||
### Edit hosts file
|
||||
### Run updates
|
||||
|
||||
```bash
|
||||
nano /opt/update-manager/hosts.conf
|
||||
update-manager update
|
||||
```
|
||||
|
||||
Example:
|
||||
|
||||
```txt
|
||||
# name ip user
|
||||
lanx-ai 172.16.5.135 ed
|
||||
lanx-www 172.16.5.140 ed
|
||||
lanx-modoboa 172.16.5.130 ed
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### Run check
|
||||
|
||||
```bash
|
||||
update-manager check
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## 🧠 Notes
|
||||
|
||||
* Hosts file is created automatically on first run
|
||||
* Lines starting with `#` are ignored
|
||||
* Empty lines are ignored
|
||||
* Requires passwordless SSH access
|
||||
|
||||
---
|
||||
|
||||
## 🔐 SSH Setup (Required)
|
||||
|
||||
Generate SSH key (if needed):
|
||||
|
||||
```bash
|
||||
ssh-keygen
|
||||
```
|
||||
|
||||
Copy key to hosts:
|
||||
|
||||
```bash
|
||||
ssh-copy-id user@host
|
||||
```
|
||||
|
||||
Test access:
|
||||
|
||||
```bash
|
||||
ssh user@host
|
||||
```
|
||||
|
||||
✔ No password prompt = ready
|
||||
|
||||
---
|
||||
|
||||
## 🖥️ Terminal UI
|
||||
|
||||
Interactive menu for managing hosts.
|
||||
|
||||
### Start UI
|
||||
|
||||
```bash
|
||||
update-manager-ui
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### UI Features
|
||||
|
||||
* Check all hosts
|
||||
* View hosts file
|
||||
* Edit hosts file
|
||||
* Add host
|
||||
* Remove host
|
||||
|
||||
---
|
||||
|
||||
## 📁 File Structure
|
||||
|
||||
```txt
|
||||
```
|
||||
/opt/update-manager/
|
||||
├── update-manager.sh
|
||||
├── update-manager-ui.sh
|
||||
├── update-manager.conf
|
||||
├── hosts.conf
|
||||
└── update-manager.conf
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## ⚙️ Configuration
|
||||
## 🧠 How it works
|
||||
|
||||
Default config:
|
||||
|
||||
```bash
|
||||
/etc/update-manager.conf
|
||||
```
|
||||
|
||||
Example:
|
||||
|
||||
```bash
|
||||
HOSTS_FILE="/opt/update-manager/hosts.conf"
|
||||
SSH_OPTIONS="-o BatchMode=yes -o ConnectTimeout=5"
|
||||
```
|
||||
* Uses SSH to connect to each host
|
||||
* Runs `apt` commands remotely
|
||||
* No agents or services needed
|
||||
* Designed for small to medium setups
|
||||
|
||||
---
|
||||
|
||||
## 🔧 Commands
|
||||
## 🔐 Requirements
|
||||
|
||||
```bash
|
||||
update-manager check # Check all hosts
|
||||
update-manager update # Run updates on all hosts
|
||||
```
|
||||
* SSH access to all hosts
|
||||
* SSH keys recommended (no password prompts)
|
||||
* Ubuntu/Debian-based systems
|
||||
|
||||
---
|
||||
|
||||
## 💡 Philosophy
|
||||
## 🧩 Future ideas
|
||||
|
||||
* Keep it simple
|
||||
* Keep it transparent
|
||||
* No hidden magic
|
||||
* Pure SSH control
|
||||
* CLI menu (interactive UI)
|
||||
* Web interface
|
||||
* Email reporting
|
||||
* Integration with monitoring systems
|
||||
|
||||
---
|
||||
|
||||
## 🧱 Future Ideas
|
||||
## 🦊 Author
|
||||
|
||||
* Email reports (cron)
|
||||
* Ntfy messages
|
||||
* Optional web UI
|
||||
|
||||
|
||||
---
|
||||
|
||||
## ❤️ Built for Lanx
|
||||
|
||||
Designed for clean infrastructure, not enterprise chaos.
|
||||
|
||||
Developed by Ed & # ⚙️ update-manager
|
||||
|
||||
Simple CLI tool for checking and managing updates across multiple Linux hosts over SSH.
|
||||
|
||||
Built for speed, clarity, and control — no fluff.
|
||||
|
||||
---
|
||||
|
||||
## 🚀 Features
|
||||
|
||||
* Check for available updates on all hosts
|
||||
* Run updates remotely via SSH
|
||||
* Simple host configuration file
|
||||
* Interactive terminal UI (whiptail)
|
||||
* Lightweight and dependency-minimal
|
||||
|
||||
---
|
||||
|
||||
## 📦 Installation (Full Setup)
|
||||
|
||||
### 1. Clone repo
|
||||
|
||||
```bash
|
||||
git clone https://github.com/your-repo/update-manager.git
|
||||
cd update-manager
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 2. Create install directory
|
||||
|
||||
```bash
|
||||
sudo mkdir -p /opt/update-manager
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 3. Copy files
|
||||
|
||||
```bash
|
||||
sudo cp update-manager.sh /opt/update-manager/
|
||||
sudo cp update-manager-ui.sh /opt/update-manager/ 2>/dev/null
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 4. Make executable
|
||||
|
||||
```bash
|
||||
sudo chmod +x /opt/update-manager/update-manager.sh
|
||||
sudo chmod +x /opt/update-manager/update-manager-ui.sh 2>/dev/null
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 5. Create symlinks
|
||||
|
||||
```bash
|
||||
sudo ln -sf /opt/update-manager/update-manager.sh /usr/local/bin/update-manager
|
||||
sudo ln -sf /opt/update-manager/update-manager-ui.sh /usr/local/bin/update-manager-ui 2>/dev/null
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 6. Install dependencies
|
||||
|
||||
```bash
|
||||
sudo apt update && sudo apt install -y whiptail openssh-client
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 7. First run (creates config)
|
||||
|
||||
```bash
|
||||
update-manager check
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## ⚡ Quick Start (1 minute)
|
||||
|
||||
### Edit hosts file
|
||||
|
||||
```bash
|
||||
nano /opt/update-manager/hosts.conf
|
||||
```
|
||||
|
||||
Example:
|
||||
|
||||
```txt
|
||||
# name ip user
|
||||
lanx-ai 172.16.5.135 ed
|
||||
lanx-www 172.16.5.140 ed
|
||||
lanx-modoboa 172.16.5.130 ed
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### Run check
|
||||
|
||||
```bash
|
||||
update-manager check
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## 🧠 Notes
|
||||
|
||||
* Hosts file is created automatically on first run
|
||||
* Lines starting with `#` are ignored
|
||||
* Empty lines are ignored
|
||||
* Requires passwordless SSH access
|
||||
|
||||
---
|
||||
|
||||
## 🔐 SSH Setup (Required)
|
||||
|
||||
Generate SSH key (if needed):
|
||||
|
||||
```bash
|
||||
ssh-keygen
|
||||
```
|
||||
|
||||
Copy key to hosts:
|
||||
|
||||
```bash
|
||||
ssh-copy-id user@host
|
||||
```
|
||||
|
||||
Test access:
|
||||
|
||||
```bash
|
||||
ssh user@host
|
||||
```
|
||||
|
||||
✔ No password prompt = ready
|
||||
|
||||
---
|
||||
|
||||
## 🖥️ Terminal UI
|
||||
|
||||
Interactive menu for managing hosts.
|
||||
|
||||
### Start UI
|
||||
|
||||
```bash
|
||||
update-manager-ui
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### UI Features
|
||||
|
||||
* Check all hosts
|
||||
* View hosts file
|
||||
* Edit hosts file
|
||||
* Add host
|
||||
* Remove host
|
||||
|
||||
---
|
||||
|
||||
## 📁 File Structure
|
||||
|
||||
```txt
|
||||
/opt/update-manager/
|
||||
├── update-manager.sh
|
||||
├── update-manager-ui.sh
|
||||
├── hosts.conf
|
||||
└── update-manager.conf
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## ⚙️ Configuration
|
||||
|
||||
Default config:
|
||||
|
||||
```bash
|
||||
/etc/update-manager.conf
|
||||
```
|
||||
|
||||
Example:
|
||||
|
||||
```bash
|
||||
HOSTS_FILE="/opt/update-manager/hosts.conf"
|
||||
SSH_OPTIONS="-o BatchMode=yes -o ConnectTimeout=5"
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## 🔧 Commands
|
||||
|
||||
```bash
|
||||
update-manager check # Check all hosts
|
||||
update-manager update # Run updates on all hosts
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## 💡 Philosophy
|
||||
|
||||
* Keep it simple
|
||||
* Keep it transparent
|
||||
* No hidden magic
|
||||
* Pure SSH control
|
||||
|
||||
---
|
||||
|
||||
## 🧱 Future Ideas
|
||||
|
||||
* Email reports (cron)
|
||||
* Optional web UI
|
||||
* Integration with Lanx monitoring
|
||||
|
||||
---
|
||||
|
||||
## ❤️ Built for Lanx
|
||||
|
||||
Designed for clean infrastructure, not enterprise chaos.
|
||||
|
||||
Developed by Ed & NodeFox
|
||||
Built with ❤️ for Lanx by **NodeFox**
|
||||
|
|
|
|||
BIN
update-manager-ui.png
Normal file
BIN
update-manager-ui.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 409 KiB |
Loading…
Add table
Add a link
Reference in a new issue