From 2422d2cd506911430758f1ff56ef415f2bce6642 Mon Sep 17 00:00:00 2001 From: Stephen Klein Date: Sat, 19 Jul 2025 07:36:03 -0400 Subject: [PATCH] Update documentation for HOPS v3.3.0 automatic update features MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Update README.md with new update functionality and command-line flags - Add comprehensive v3.3.0 changelog entry with all new features - Update version badges and feature highlights - Fix script references from hops.sh to hops across all documentation - Add upgrade path documentation for automatic updates - Update management command examples 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- ADVANCED.md | 2 +- CHANGELOG.md | 45 +++++++++++++++++++++++++++++++++++++++++++-- INSTALLATION.md | 8 ++++---- README.md | 21 +++++++++++++++++---- 4 files changed, 65 insertions(+), 11 deletions(-) diff --git a/ADVANCED.md b/ADVANCED.md index b7a0265..c1ee882 100644 --- a/ADVANCED.md +++ b/ADVANCED.md @@ -263,7 +263,7 @@ hops/ ├── privileged-setup # Root-only operations ├── user-operations # User operations ├── services-improved # Enhanced service definitions -└── hops.sh # Legacy main script +└── hops # Main script ``` #### Using Library Functions diff --git a/CHANGELOG.md b/CHANGELOG.md index 61482b2..128eb80 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,35 @@ All notable changes to HOPS will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [3.3.0] - 2025-01-19 + +### Added +- **🔄 Automatic Updates**: Git-based update mechanism with backup functionality +- **📱 Command Line Interface**: New flags for update management + - `--update`: Update HOPS to latest version automatically + - `--check-updates`: Check for available updates (returns exit code 1 if updates available) + - `--version`: Display current version information + - `--help`: Show comprehensive help and usage information +- **🛡️ Safe Updates**: Automatic backup of local changes before updating +- **📋 Change Tracking**: Display recent changes and version comparison during updates +- **🎛️ Interactive Updates**: Update checking integrated into main menu (option 6) + +### Changed +- **Version Numbering**: Updated to v3.3.0 across all components +- **Menu Structure**: Added "Check for Updates" as menu option 6, shifted other options +- **Documentation**: Updated README.md and CLAUDE.md with new update functionality +- **Color Code Handling**: Removed duplicate color definitions, now sourced from lib/common.sh + +### Fixed +- **Script Compatibility**: Resolved readonly variable conflicts between main script and libraries +- **Update Process**: Robust error handling and rollback for failed updates +- **Exit Codes**: Proper exit codes for command-line operations + +### Security +- **Backup Protection**: Local changes are automatically backed up before any updates +- **Git Validation**: Comprehensive validation that HOPS is in a git repository before updates +- **Privilege Handling**: Updates require appropriate privileges (root/sudo) for system changes + ## [3.2.0] - 2024-07-18 ### Added @@ -159,14 +188,26 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## Version Support -- **v3.2.x**: Current stable release with full platform support +- **v3.3.x**: Current stable release with automatic update support +- **v3.2.x**: Previous stable release, upgrade recommended - **v3.1.x**: Beta features, limited support - **v3.0.x**: Legacy support for critical bugs only - **v2.x and earlier**: No longer supported ## Upgrade Path -### From v3.1.x to v3.2.0 +### From v3.2.x to v3.3.0 (Recommended - Automatic) +```bash +# Use built-in update system +cd /path/to/hops +sudo ./hops --update + +# Or use interactive menu +sudo ./hops +# Select option 6: Check for Updates +``` + +### From v3.1.x to v3.3.0 (Manual) ```bash # Backup current installation sudo tar -czf hops-backup-$(date +%Y%m%d).tar.gz ~/hops /opt/appdata diff --git a/INSTALLATION.md b/INSTALLATION.md index bd5982c..e2e33f3 100644 --- a/INSTALLATION.md +++ b/INSTALLATION.md @@ -55,7 +55,7 @@ sudo ./privileged-setup # Root operations ./user-operations deploy # Deploy services # Legacy method (still supported) -sudo ./hops.sh +sudo ./hops ``` ### What Gets Installed @@ -232,7 +232,7 @@ sudo ./privileged-setup # Root-only operations ### Option 3: Legacy Installation ```bash -sudo ./hops.sh +sudo ./hops ``` - **Compatibility**: Original installation method - **Full-Featured**: Complete management interface @@ -243,7 +243,7 @@ sudo ./hops.sh ### Check Service Status ```bash # Via HOPS management interface -sudo ./hops.sh +sudo ./hops # Select option 4: Service Status # Via user operations @@ -324,7 +324,7 @@ wsl -d Ubuntu-22.04 - **System Logs**: `journalctl -u docker` ### Getting Help -1. **Built-in Help**: `sudo ./hops.sh` → Option 7 +1. **Built-in Help**: `sudo ./hops` → Option 7 2. **Check Logs**: Review installation logs for errors 3. **Verify Prerequisites**: Ensure all system requirements are met 4. **Docker Status**: Confirm Docker is running and accessible diff --git a/README.md b/README.md index 214dc70..66c1f15 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # HOPS - Homelab Orchestration Provisioning Script [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) -[![Version](https://img.shields.io/badge/Version-3.2.0-blue.svg)]() +[![Version](https://img.shields.io/badge/Version-3.3.0-blue.svg)]() [![Platform](https://img.shields.io/badge/Platform-Linux%20%7C%20macOS%20%7C%20Windows-orange.svg)]() **HOPS** is a comprehensive automation tool for deploying homelab infrastructure using Docker Compose. Deploy and manage popular homelab services including media servers, download clients, monitoring tools, and more through an intuitive menu-driven interface. @@ -14,7 +14,13 @@ - **macOS**: ✅ Recently improved with v3.2.0 fixes - **Windows (WSL2)**: ⚠️ Limited testing -## 🆕 What's New in v3.2.0 +## 🆕 What's New in v3.3.0 +- **🔄 Automatic Updates**: Git-based update system with backup functionality +- **📱 Command Line Interface**: `--update`, `--check-updates`, `--version`, `--help` flags +- **🛡️ Safe Updates**: Automatic backup of local changes before updating +- **📋 Change Tracking**: View recent changes and version comparison + +### Previous Updates (v3.2.0) - **Enhanced macOS Support**: Docker Desktop integration, keychain authentication, user directory fixes - **Caddy Support**: Added reverse proxy option (user provides configuration) - **Bug Fixes**: Password generation, container creation, healthchecks, file permissions @@ -25,7 +31,8 @@ - **🚀 Easy Installation**: One-command setup with automatic Docker installation - **🔒 Security First**: Encrypted secrets, firewall configuration, input validation - **📊 Management**: Real-time monitoring, centralized logs, service control -- **🔄 Reliability**: Error handling, rollback capabilities, dependency management +- **🔄 Auto-Updates**: Built-in update system with backup protection +- **🔧 Reliability**: Error handling, rollback capabilities, dependency management - **🌐 Cross-Platform**: Linux, macOS, and Windows (WSL2) support ## 📱 Supported Services @@ -76,7 +83,13 @@ sudo ./setup ```bash # Access management interface -sudo ./hops.sh +sudo ./hops + +# Update HOPS +sudo ./hops --update # Update to latest version +sudo ./hops --check-updates # Check for updates +./hops --version # Show version +./hops --help # Show help # Service operations (no sudo required) ./user-operations status # View service status