{"id":15203996,"url":"https://github.com/lzh-1625/go_process_manager","last_synced_at":"2025-10-29T04:31:38.879Z","repository":{"id":246210529,"uuid":"820422105","full_name":"lzh-1625/go_process_manager","owner":"lzh-1625","description":"Implement a process management tool in Go.","archived":false,"fork":false,"pushed_at":"2025-02-09T05:44:19.000Z","size":8545,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-09T06:19:55.057Z","etag":null,"topics":["elasticsearch","go","process-manager","pty","terminal","websocket","webui"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lzh-1625.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-06-26T12:42:30.000Z","updated_at":"2025-02-07T17:10:25.000Z","dependencies_parsed_at":"2024-06-26T15:46:15.650Z","dependency_job_id":"bcd9b28c-b646-4dea-99b2-0658497d508c","html_url":"https://github.com/lzh-1625/go_process_manager","commit_stats":{"total_commits":13,"total_committers":2,"mean_commits":6.5,"dds":0.3846153846153846,"last_synced_commit":"d2d9757b8844bc113548629dce6371b325ed2cd9"},"previous_names":["lzh-1625/x_process_manager","lzh-1625/go_process_manager"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lzh-1625%2Fgo_process_manager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lzh-1625%2Fgo_process_manager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lzh-1625%2Fgo_process_manager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lzh-1625%2Fgo_process_manager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lzh-1625","download_url":"https://codeload.github.com/lzh-1625/go_process_manager/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":238768422,"owners_count":19527197,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["elasticsearch","go","process-manager","pty","terminal","websocket","webui"],"created_at":"2024-09-28T05:04:56.771Z","updated_at":"2025-10-29T04:31:38.874Z","avatar_url":"https://github.com/lzh-1625.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n  \u003cbr/\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/lzh-1625/go_process_manager/refs/heads/master/resources/templates/favicon.ico\" alt=\"GPM logo\"\u003e\n  \u003cbr/\u003e\n\u003c/div\u003e\n\n\n# Go Process Manager\n\nGo Process Manager is a process management tool developed based on Golang, offering process management capabilities similar to `screen`, and supports Web UI for visual operations. This tool integrates log management, permission control, process performance monitoring, status push, and more. It supports CPU and memory limits through `cgroup` and also provides task management and scheduled task functionalities.\n\n---\n\n## [中文](./README_CN.md)\n\n## Features\n\n### Core Features\n\n- **Process Management**: Supports creating, starting, stopping, restarting, and deleting processes, providing multi-process management capabilities similar to `screen`.\n- **Web UI for Visual Operations**: Offers a user-friendly web interface, allowing users to easily manage processes, view logs, and monitor performance through a browser.\n- **Log Management**: Supports storing logs in Elasticsearch 8 or SQLite, providing efficient log query and analysis capabilities.\n- **Permission Management**: Provides role-based access control with three roles (root, admin, user), ensuring system security and flexibility.\n- **Process Performance Monitoring**: Real-time monitoring of CPU, memory, and other resource usage, helping users optimize system performance.\n- **Process Status Push**: Supports real-time status push for processes, allowing users to receive the latest process status via Web UI or API.\n- **Resource Limits**: Implements CPU and memory limits through `cgroup`, preventing processes from consuming excessive system resources.\n- **Task Management**: Supports task management, scheduled tasks, and API calls, meeting the needs of automated operations.\n\n---\n\n### Terminal Types\n\n- **pty (Pseudo Terminal)**: Based on pseudo terminals, supports ANSI characters and shortcut key operations, suitable for interactive command-line programs.\n- **std (Standard Input/Output)**: Based on standard input/output pipes, suitable for non-interactive programs or scripts.\n\n---\n\n## Role Permissions\n\n| Role  | Role Management | Process Creation | Process Control | Log Viewing | Task Management |\n| ----- | --------------- | ---------------- | --------------- | ----------- | --------------- |\n| root  | ✔              | ✔               | ✔              | ✔          | ✔              |\n| admin | ×              | ×               | ✔              | ✔          | ✔              |\n| user  | ×              | ×               | Custom          | Custom      | ×              |\n\n- **root**: Has the highest permissions, can manage all processes, logs, and user roles.\n- **admin**: Can control processes and view logs but cannot create processes or manage roles.\n- **user**: Permissions can be customized, suitable for regular users.\n\n---\n\n## User Guide\n\n### Starting the Process\n\n#### Windows\n\n1. Download the Windows version of the binary file.\n2. Double-click to run and start the service.\n\n#### Linux\n\n1. Download the Linux version of the binary file.\n2. Use the following commands to grant execution permissions and start:\n\n   ```bash\n   chmod 777 ./go_process_manager\n   ./go_process_manager\n   ```\n\n### Web Interface\n\n1. After starting the service, access `http://[ip]:8797`.\n2. Log in with the default credentials `root/root`.\n\n### Demo\n\nVisit the [Demo](http://xcon.top:9787/process) to experience the features. Use the credentials `root/root` to log in.\n\n---\n\n## Interface Showcase\n\n### Process Management\n\n![Process Management Interface](https://github.com/lzh-1625/go_process_manager/assets/59822923/50f31b99-41d4-4d8c-88fe-20c978385155)\n\n- **Process List**: Displays all running processes, including process ID, name, status, resource usage, etc.\n- **Action Buttons**: Supports starting, stopping, restarting, and deleting processes.\n\n### Terminal Operations\n\n![Terminal Operations Interface](https://github.com/lzh-1625/go_process_manager/assets/59822923/63eb6bec-353f-4d12-a1d9-95d89fccdac3)\n\n- **Terminal Emulation**: Supports ANSI characters and shortcut key operations, providing an experience similar to a local terminal.\n- **Input/Output**: Real-time display of process standard input and output.\n\n### Log Viewing\n\n![Log Viewing Interface](https://github.com/lzh-1625/go_process_manager/assets/59822923/6af8e228-7709-45c5-aba8-4b61dc825026)\n\n- **Log Query**: Supports filtering logs by time, process ID, operator, etc.\n\n---\n\n## Additional Notes\n\n### Log Management\n\n- **Elasticsearch 8**: Suitable for large-scale log storage and query, supports distributed deployment.\n- **SQLite**: Lightweight log storage, suitable for single-machine or small-scale use.\n\n### Permission Control\n\n- **root User**: Has the highest permissions, can manage all processes, logs, and user roles.\n- **admin User**: Can control processes and view logs, suitable for operations personnel.\n- **user User**: Permissions can be customized, suitable for regular users or developers.\n\n### Resource Limits\n\n- **CPU Limits**: Set CPU usage limits for processes through `cgroup`.\n- **Memory Limits**: Set memory usage limits for processes through `cgroup`.\n\n### Task Management\n\n- **Scheduled Tasks**: Supports Cron expressions, allowing users to create scheduled tasks.\n- **API Calls**: Provides APIs to trigger tasks.\n- **Task Flow**: Chain execution of tasks.\n- **Trigger Events**: Trigger tasks through process stop, start, or exceptions.\n\n---\n\n## Development and Deployment\n\n### Environment Requirements\n\n- **Golang**: Version 1.18 or higher.\n- **Elasticsearch 8** (optional): For log storage.\n- **SQLite** (optional): For lightweight log storage.\n\n### Compilation and Execution\n\n1. Clone the project:\n\n   ```bash\n   git clone https://github.com/lzh-1625/go_process_manager.git\n   cd go_process_manager\n   ```\n2. Compile the project:\n\n   ```bash\n   go build -o go_process_manager\n   ```\n3. Run the project:\n\n   ```bash\n   ./go_process_manager\n   ```\n\n---\n\n## Contributions and Feedback\n\nWe welcome submitting Issues and Pull Requests to help improve Go Process Manager. If you have any questions or suggestions, please provide feedback via [GitHub Issues](https://github.com/lzh-1625/go_process_manager/issues).\n\n---\n\n## License\n\nThis project is licensed under the [MIT License](https://opensource.org/licenses/MIT). For more details, please refer to the [LICENSE](LICENSE) file.\n\n---\n\n## Contact Us\n\n- **Author**: lzh-1625\n- **GitHub**: [go_process_manager](https://github.com/lzh-1625/go_process_manager)\n\nThank you for using Go Process Manager! We hope this tool brings convenience to your process management.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flzh-1625%2Fgo_process_manager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flzh-1625%2Fgo_process_manager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flzh-1625%2Fgo_process_manager/lists"}