{"id":32532694,"url":"https://github.com/yosebyte/cgent","last_synced_at":"2025-10-28T12:55:57.249Z","repository":{"id":262838895,"uuid":"884049365","full_name":"yosebyte/cgent","owner":"yosebyte","description":"Containerized Nezha-agent","archived":false,"fork":false,"pushed_at":"2025-08-24T07:08:08.000Z","size":65,"stargazers_count":52,"open_issues_count":0,"forks_count":6,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-24T14:07:01.706Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Dockerfile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/yosebyte.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"zenodo":null}},"created_at":"2024-11-06T03:30:49.000Z","updated_at":"2025-08-24T07:07:30.000Z","dependencies_parsed_at":"2024-11-14T15:39:46.097Z","dependency_job_id":"bca3729b-2a0e-4202-8e86-a94381a05c91","html_url":"https://github.com/yosebyte/cgent","commit_stats":null,"previous_names":["yosebyte/cgent"],"tags_count":32,"template":false,"template_full_name":null,"purl":"pkg:github/yosebyte/cgent","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yosebyte%2Fcgent","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yosebyte%2Fcgent/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yosebyte%2Fcgent/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yosebyte%2Fcgent/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/yosebyte","download_url":"https://codeload.github.com/yosebyte/cgent/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yosebyte%2Fcgent/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":281441020,"owners_count":26501758,"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","status":"online","status_checked_at":"2025-10-28T02:00:06.022Z","response_time":60,"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":[],"created_at":"2025-10-28T12:55:56.336Z","updated_at":"2025-10-28T12:55:57.233Z","avatar_url":"https://github.com/yosebyte.png","language":"Dockerfile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Cgent - Containerized Nezha-agent\n\nCgent provides a containerized implementation of Nezha-agent, offering enhanced security through container isolation while maintaining full functionality.\n\n## Features\n\n- **Containerized Security**: Nezha agent runs inside a container with restricted access for enhanced safety\n- **Auto-Configuration**: Minimal configuration file automatically generated on first run\n- **Nezha v1 Support**: Full compatibility with Nezha monitoring system v1\n- **Lightweight**: Based on Alpine Linux, minimal resource usage\n- **Multi-Architecture**: Supports both `linux/amd64` and `linux/arm64` platforms\n\n## Quick Start\n\nCreate a directory for persistent storage and run the container:\n\n```bash\nmkdir -p /root/cgent\ndocker run -d -v=/root/cgent/:/root/ \\\n    --name=cgent \\\n    --restart=always \\\n    --net=host \\\n    --cap-add=NET_RAW \\\n    -e SECRET=agentsecretkey \\\n    -e SERVER=installhost \\\n    -e TLS=true \\\n    ghcr.io/yosebyte/cgent\n```\n\nView the generated configuration:\n\n```bash\ncat /root/cgent/config.yml\n```\n\n## Configuration Options\n\n| Environment Variable | Description | Default |\n|---|---|---|\n| `SECRET` | Nezha agent secret key from dashboard | *Required* |\n| `SERVER` | Nezha dashboard hostname or IP | *Required* |\n| `TLS` | Enable/disable TLS connection | `false` |\n\n## Important Notes\n\n- Each time the container creates a new configuration file, a different `UUID` is generated\n- Always backup `/root/cgent/config.yml` before upgrading the container\n- Find your `SECRET`, `SERVER`, and TLS settings in your Nezha dashboard configuration\n\n## Nezha Dashboard Deployment (Optional)\n\nIf you need to deploy a Nezha dashboard as well:\n\n```bash\nmkdir -p /root/nezha\ndocker run -d -v=/root/nezha/:/dashboard/data/ \\\n    --name=nezha \\\n    --restart=always \\\n    --net=host \\\n    ghcr.io/nezhahq/nezha\n```\n\nView the dashboard configuration:\n\n```bash\ncat /root/nezha/config.yaml\n```\n\n**Important**: Always backup `/root/nezha/config.yaml` and `/root/nezha/sqlite.db` before upgrading the dashboard container.\n\n## About Nezha\n\nNezha is a server monitoring system that tracks metrics such as CPU, memory, network usage, and more. This containerized agent connects to a Nezha dashboard to report monitoring data from your system.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyosebyte%2Fcgent","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyosebyte%2Fcgent","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyosebyte%2Fcgent/lists"}