{"id":51422935,"url":"https://github.com/salvatorecorvaglia/raven","last_synced_at":"2026-07-05T01:01:13.660Z","repository":{"id":362575756,"uuid":"1259767916","full_name":"salvatorecorvaglia/raven","owner":"salvatorecorvaglia","description":"A system monitor that works on Linux, BSD, macOS, and Windows","archived":false,"fork":false,"pushed_at":"2026-06-20T22:06:54.000Z","size":252,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-06-20T22:09:34.588Z","etag":null,"topics":["cli","cross-platform","devops","docker","fastapi","htop","monitoring","neofetch","plugin-architecture","psutil","python","remote-monitoring","rest-api","system-monitor","textual","tui","web-dashboard"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/raven-monitor","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/salvatorecorvaglia.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-06-04T20:53:26.000Z","updated_at":"2026-06-20T22:06:58.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/salvatorecorvaglia/raven","commit_stats":null,"previous_names":["salvatorecorvaglia/raven"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/salvatorecorvaglia/raven","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/salvatorecorvaglia%2Fraven","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/salvatorecorvaglia%2Fraven/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/salvatorecorvaglia%2Fraven/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/salvatorecorvaglia%2Fraven/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/salvatorecorvaglia","download_url":"https://codeload.github.com/salvatorecorvaglia/raven/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/salvatorecorvaglia%2Fraven/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35140189,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-04T02:00:05.987Z","response_time":113,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["cli","cross-platform","devops","docker","fastapi","htop","monitoring","neofetch","plugin-architecture","psutil","python","remote-monitoring","rest-api","system-monitor","textual","tui","web-dashboard"],"created_at":"2026-07-05T01:01:12.900Z","updated_at":"2026-07-05T01:01:13.653Z","avatar_url":"https://github.com/salvatorecorvaglia.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Raven 🐦‍⬛\n\n**A system monitor that works on Linux, BSD, macOS, and Windows.**\n\n---\n\n## 🌟 Key Features\n\n* **⚡ Gorgeous Dashboards**:\n  * **TUI Dashboard**: Built with [Textual](https://textual.textualize.io/), offering smooth animations, color themes, real-time widgets, and flicker-free updates.\n  * **Web Dashboard**: An elegant web UI powered by FastAPI and Vanilla HTML/CSS/JS. Features premium loading shimmers, connection status toasts, and dynamic charts.\n* **🐦‍⬛ Neofetch-style Fetch**: A quick terminal command to fetch system hardware specs, platform info, and resources.\n* **🔒 Remote Monitoring**: Run a secure agent on a remote server with timing-attack resistant API key authentication, and visualize its metrics locally.\n* **🔌 Extensible Plugins**: Easily write your own metrics collectors by inheriting from [MonitorPlugin](raven/plugins/base.py#L13).\n* **📈 High Performance**: Metrics are queried in parallel via thread pools, with smart caching and lightweight process queries to minimize CPU overhead.\n* **📥 Multi-format Exporting**: Print metrics directly to your terminal or save them as CSV, JSON, or plaintext.\n\n---\n\n## 🛠 Project Structure\n\nRaven is structured cleanly to separate collection logic, plugins, and frontends:\n\n* [raven/cli.py](raven/cli.py): CLI routing and argument definitions.\n* [raven/config.py](raven/config.py): TOML configuration schemas and verification logic.\n* [raven/core/](raven/core/): Central coordinator containing the collector agent, type definitions, background server runner, and standard protocol interfaces.\n* [raven/plugins/](raven/plugins/): Discovered monitoring plugins (CPU, Memory, Disk, Containers, Network, Sensors, Processes, etc.).\n* [raven/tui/](raven/tui/): Textual terminal widgets and layout CSS stylesheets (`.tcss`).\n* [raven/web/](raven/web/): FastAPI backend and static web dashboard assets.\n* [raven/remote/](raven/remote/): Server agent and client tools for remote metric sync.\n* [raven/export/](raven/export/): Formatted data exporters.\n\n---\n\n## 🚀 Getting Started\n\n### 1. Prerequisites\n* **Python 3.11+**\n* `uv` (recommended) or `pip`\n\n### 2. Installation \u0026 Setup\nTo install dependencies and prepare the environment:\n\n```bash\n# Clone the repository\ngit clone https://github.com/salvatorecorvaglia/raven.git\ncd raven\n\n# Sync virtual environment and download dependencies\nuv sync --all-extras --dev\n```\n\n---\n\n## 💻 Usage \u0026 CLI Guide\n\nRaven offers a simple command-line structure routed through [raven/cli.py](raven/cli.py):\n\n### 1. Start the TUI (Default)\nRun Raven with no arguments to launch the Textual TUI dashboard:\n```bash\nuv run raven\n```\n\n### 2. Start the Web Dashboard\nExpose a web-based dashboard utilizing FastAPI:\n```bash\nuv run raven web\n# Options:\n#   --host Hostname to bind to (e.g. 127.0.0.1)\n#   --port Port to run server on (e.g. 8080)\n```\n\n### 3. Start a Remote Monitoring Agent\nTo monitor a remote server, run the daemon agent on the remote host:\n```bash\nuv run raven serve --host 127.0.0.1 --port 9090\n```\n\n### 4. Connect to a Remote Agent\nYou can direct your TUI, Web server, or exporters to read metrics from a running remote agent:\n```bash\nuv run raven --remote http://192.168.1.50:9090\n```\n\n### 5. Fetch a Quick System Summary\nGet a quick `neofetch`-style output of your server specifications:\n```bash\nuv run raven fetch\n```\n\n### 6. Export Metrics to Stdout\nPrint system details to the terminal in JSON, CSV, or formatted text:\n```bash\n# Print all modules once as text\nuv run raven print\n\n# Print specific modules formatted as JSON\nuv run raven print cpu memory --format json\n```\n\n---\n\n## ⚙️ Configuration\n\nRaven searches for settings in the following order:\n1. `--config` / `-c` CLI option.\n2. `./raven.toml` in the current working directory.\n3. `~/.config/raven/raven.toml`.\n4. Fall back to internal defaults.\n\nRefer to [raven.example.toml](raven.example.toml) for customising ports, intervals, enabled modules, and security parameters:\n\n```toml\n[general]\nrefresh_interval = 2        # seconds between updates\ntheme = \"dark\"\n\n[modules]\ncpu = true\nmemory = true\ndisk = true\nnetwork = true\nprocesses = true\nusers = true\nsensors = true\ncontainers = true\n\n[web]\nenabled = false\nhost = \"127.0.0.1\"\nport = 8080\napi_key = \"\"                # Empty = no authentication\n\n[remote]\nenabled = false\nhost = \"127.0.0.1\"\nport = 9090\napi_key = \"\"\n```\n\n---\n\n## 🔌 Creating Custom Plugins\n\nAll metrics collection modules are structured as plugins. To add your own custom collector:\n\n1. Create a Python file under the [raven/plugins/](raven/plugins/) directory.\n2. Subclass [MonitorPlugin](raven/plugins/base.py#L13) and implement the abstract methods:\n\n```python\nfrom raven.plugins.base import MonitorPlugin\n\nclass CustomMetricsPlugin(MonitorPlugin):\n    name = \"my_custom_metrics\"\n    category = \"general\"\n\n    def is_available(self) -\u003e bool:\n        # Check system compatibility or dependencies here\n        return True\n\n    def collect(self) -\u003e dict:\n        # Collect and return your metrics\n        return {\n            \"custom_metric_1\": 42,\n            \"status\": \"online\"\n        }\n```\n\n3. Enable or customize your module inside your `raven.toml` under the `[modules]` header.\n\n\u003e [!TIP]\n\u003e **Thread Safety**: If your plugin keeps state between collection cycles (e.g. counters or cached query data), use a thread lock (such as `threading.Lock`) to make sure it is safe to access from parallel collection threads.\n\n---\n\n## 🧪 Testing \u0026 Development\n\nWe use `pytest` for automated test suites. Before submitting pull requests, run:\n\n```bash\n# Run the test suite\nuv run pytest\n\n# Check code formatting \u0026 lint issues\nuv run ruff check\n\n# Apply formatting\nuv run ruff format\n```\n\n---\n\n## 🤝 Contributing\n\nContributions are welcome! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.\n\n## 🔐 Security\n\nIf you discover a security vulnerability, please see our [Security Policy](SECURITY.md).\n\n## 📝 License\n\nDistributed under the MIT License. See [LICENSE](LICENSE) for more information.\n\n---\n\n**Author**: [Salvatore Corvaglia](https://github.com/salvatorecorvaglia)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsalvatorecorvaglia%2Fraven","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsalvatorecorvaglia%2Fraven","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsalvatorecorvaglia%2Fraven/lists"}