{"id":34815168,"url":"https://github.com/harmeshgv/cloudmind","last_synced_at":"2026-04-06T21:31:04.725Z","repository":{"id":326553550,"uuid":"1095568977","full_name":"harmeshgv/cloudmind","owner":"harmeshgv","description":"AI-powered cloud orchestration system using FastAPI agents, Terraform, Ansible, and LLM reasoning for real-time monitoring, diagnostics, and autonomous infrastructure management.","archived":false,"fork":false,"pushed_at":"2025-11-28T15:58:58.000Z","size":15,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-11-30T21:38:22.848Z","etag":null,"topics":["ansible","aws","infrastructure-as-code","large-language-models","terraform"],"latest_commit_sha":null,"homepage":"","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/harmeshgv.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-11-13T08:19:44.000Z","updated_at":"2025-11-28T15:59:02.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/harmeshgv/cloudmind","commit_stats":null,"previous_names":["harmeshgv/cloudmind"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/harmeshgv/cloudmind","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/harmeshgv%2Fcloudmind","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/harmeshgv%2Fcloudmind/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/harmeshgv%2Fcloudmind/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/harmeshgv%2Fcloudmind/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/harmeshgv","download_url":"https://codeload.github.com/harmeshgv/cloudmind/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/harmeshgv%2Fcloudmind/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31491094,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-06T17:22:55.647Z","status":"ssl_error","status_checked_at":"2026-04-06T17:22:54.741Z","response_time":112,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["ansible","aws","infrastructure-as-code","large-language-models","terraform"],"created_at":"2025-12-25T13:04:12.196Z","updated_at":"2026-04-06T21:31:04.707Z","avatar_url":"https://github.com/harmeshgv.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# **Cloudmind: AI-Driven Cloud Monitoring and Autonomous Configuration Framework**\n\nCloudBot is an AI-assisted cloud orchestration framework that integrates FastAPI agents, Terraform-based provisioning, Ansible automation, and an LLM-powered orchestrator for intelligent cloud monitoring and autonomous configuration management. The system deploys lightweight CloudBot Agents across EC2 instances and enables natural-language interaction through a Streamlit interface.\n\n---\n\n## **1. Features**\n\n* Distributed FastAPI agents for metrics, logs, inventory, and security insights\n* Terraform-based provisioning of AWS EC2 agent nodes\n* Automated configuration using Ansible playbooks\n* LLM-powered CloudBot Orchestrator for intelligent query interpretation\n* Streamlit conversational dashboard for monitoring and analysis\n* Fully agent-driven architecture with real-time data retrieval\n\n---\n\n## **2. System Architecture**\n\nCloudBot follows a multi-layered architecture:\n\n1. **Infrastructure Layer**\n   Terraform provision EC2 instances and networking resources.\n\n2. **Configuration Layer**\n   Ansible installs Python, FastAPI, dependencies, systemd services, and deploys CloudBot Agent.\n\n3. **Agent Layer**\n   FastAPI Agents expose endpoints:\n   `/metrics`, `/logs`, `/system-inventory`, `/security`.\n\n4. **Orchestration Layer**\n   An LLM interprets user queries, selects agents, fetches data, and generates structured Markdown summaries.\n\n5. **Interaction Layer**\n   Streamlit dashboard provides conversational monitoring and data visualization.\n\n---\n\n## **3. Prerequisites**\n\nInstall the following:\n\n* **Terraform** (≥ 1.3)\n* **Ansible**\n* **AWS CLI**\n* **Python 3.10+**\n* **pip / virtualenv**\n* **SSH keypair** (`~/.ssh/id_rsa` and `~/.ssh/id_rsa.pub`)\n* AWS account with programmatic IAM access\n\n---\n\n## **4. AWS Setup**\n\n1. Configure AWS credentials locally:\n\n   ```bash\n   aws configure\n   ```\n2. Provide:\n\n   * AWS Access Key ID\n   * AWS Secret Access Key\n   * Region (e.g., `us-east-1`)\n\n---\n\n## **5. Deployment Workflow**\n\n### **Step 1: Clone the Repository**\n\n```bash\ngit clone \u003crepo-url\u003e\ncd \u003crepo-folder\u003e\n```\n\n---\n\n### **Step 2: Provision Infrastructure (Terraform)**\n\nNavigate to the Terraform directory:\n\n```bash\ncd terraform\nterraform init\nterraform validate\nterraform plan\nterraform apply\nterraform output inventory \u003e cloudmin/ansible/inventories/host.ini\n```\n\nTerraform will:\n\n* Create SSH key pairs\n* Create a security group\n* Provision two EC2 instances\n* Output their public IPs\n* Generate dynamic Ansible inventory\n\n---\n\n### **Step 3: Deploy CloudBot Agents (Ansible)**\n\nFrom the project root:\n\n```bash\nansible-playbook -i inventories/hosts.ini deploy-agent.yml\n```\n\nAnsible will:\n\n* Install Python, FastAPI, Uvicorn, Psutil\n* Copy `app.py` to `/opt/agent/` on each instance\n* Install a systemd service for continuous execution\n* Start the CloudBot Agent on port **8000**\n\n---\n\n### **Step 4: Verify Agent Endpoints**\n\nUse curl or browser:\n\n```bash\ncurl http://\u003cagent-ip\u003e:8000/\ncurl http://\u003cagent-ip\u003e:8000/metrics\ncurl http://\u003cagent-ip\u003e:8000/system-inventory\ncurl http://\u003cagent-ip\u003e:8000/security\n```\n\nEach agent should return real-time system data.\n\n---\n\n### **Step 5: Start the CloudBot Orchestrator UI**\n\nInstall dependencies:\n\n```bash\npip install -r requirements.txt\n```\n\nSet agents info file\n\n```bash\npython -m bot.discover_agents_from_api\n```\n\nRun Streamlit:\n\n```bash\nstreamlit run app.py\n```\n\nThe UI will:\n\n* Load `agents.json`\n* Allow natural-language queries\n* Communicate with the LLM orchestrator\n* Fetch metrics/logs from agents\n* Render Markdown-based insights in real time\n\n---\n\n## **6. How the System Works**\n\n1. User enters a query (e.g., *“Show CPU usage of both agents”*).\n2. LLM interprets intent and determines which endpoints to query.\n3. Orchestrator fetches data via FastAPI endpoints from distributed agents.\n4. Results are aggregated and passed back to the LLM.\n5. LLM generates a Markdown summary displayed in Streamlit.\n6. Agents run continuously in the background using systemd.\n\n---\n\n## **7. Repository Structure**\n\n```\n/terraform           → Infrastructure (EC2, SG, keypairs)\n/ansible             → Playbooks for deploying CloudBot agent\n/agent_app           → FastAPI agent source code\n/streamlit_ui        → CloudBot LLM-based orchestration UI\nagents.json          → Discovered agent list\n```\n\n---\n\n## **8. Technologies Used**\n\n* **FastAPI** – Lightweight monitoring agents\n* **Terraform** – Infrastructure as Code\n* **Ansible** – Automated configuration management\n* **Streamlit** – Conversational UI\n* **LLM (OpenAI/Groq)** – Intelligent orchestration\n* **AWS EC2** – Cloud execution environment\n* **systemd** – Service management on agents\n\n---\n\n## **9. Future Enhancements**\n\n* Automated remediation and self-healing operations\n* Predictive analytics with ML anomaly detection\n* Multi-cloud deployment (GCP, Azure)\n* Kubernetes and container monitoring support\n* Security event correlation and threat scoring\n\n---\n\n## **10. License**\n\nMIT License (or your preferred license)\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fharmeshgv%2Fcloudmind","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fharmeshgv%2Fcloudmind","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fharmeshgv%2Fcloudmind/lists"}