Commit Graph

11 Commits

Author SHA1 Message Date
zeaslity
b28c6462f1 Enhance Network Interface Detection and Configuration Management
- Implemented robust network interface detection with `GetInterfaces()` function
- Added validation for network interface names using regex patterns
- Updated `Network` struct to improve YAML tag formatting
- Modified `Gather()` and `SaveConfig()` methods to streamline network configuration
- Removed redundant `SaveConfig()` calls in various methods
- Added comprehensive network interface name validation logic
2025-02-28 11:19:29 +08:00
zeaslity
c10554c218 [agent-wdd] 小小新增部分内容 2025-02-27 17:19:36 +08:00
zeaslity
b6cc5abc63 Refactor Disk and Memory Size Formatting with Centralized Utility Function
- Extracted common size formatting logic to a new utility function `HumanSize` in utils package
- Removed duplicate size formatting code from Disk and Memory configurations
- Updated Disk and Memory modules to use the centralized size formatting utility
- Uncommented and implemented disk usage calculation in Disk configuration
- Improved code readability and maintainability by centralizing size conversion logic
2025-02-27 15:15:55 +08:00
zeaslity
8fc55e2e28 Enhance Download Functionality with Proxy and Progress Tracking
- Implemented advanced download utility with proxy support for SOCKS5 and HTTP protocols
- Added progress tracking with human-readable file size and download percentage
- Updated go.mod and go.sum to include new dependencies for proxy and networking
- Created flexible proxy client generation for different proxy types
- Improved error handling and logging in download process
2025-02-27 15:06:40 +08:00
zeaslity
72bc56b5e5 Enhance Zsh and Config Commands, Update Network Configuration
- Implemented comprehensive Zsh installation command with multiple network scenarios
- Added 'config show' subcommand to display agent configuration
- Updated version command to print version information
- Modified Network configuration to clarify internet connectivity status
- Improved download utility with additional file existence checks
- Updated agent-wdd rules and documentation
2025-02-27 14:20:05 +08:00
zeaslity
16c041e3eb Add base system configuration commands for agent-wdd
- Implemented new base commands for system configuration:
  * swap: Disable system swap
  * selinux: Disable SELinux
  * firewall: Stop and disable firewalld and ufw
  * sysconfig: Modify system sysctl configuration
  * ssh: Add SSH-related subcommands (key, port, config)

- Updated Config.go to initialize ConfigCache with default values
- Added new utility functions in FileUtils.go for file content manipulation
- Extended Excutor.go with HardCodeCommandExecutor method
2025-02-27 10:57:58 +08:00
zeaslity
e8f0e0d4a9 123 2025-02-26 17:49:03 +08:00
zeaslity
b8170e00d4 愉快的使用cursor 2025-02-26 09:25:24 +08:00
zeaslity
ce0395ae66 [agent-wdd] 完成Excecutor和Operator部分,完成base tools部分 2025-02-14 17:17:55 +08:00
zeaslity
dabf63f10f [agent-wdd] 基本完成Info部分的整理 2025-02-13 15:29:26 +08:00
zeaslity
e826b55240 [agent-wdd] 完成自定义log部分;完成info network部分; 项目结构基本完成 2025-02-11 17:27:41 +08:00