Skip to content

khanovico/cicd-agent-code-gen

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

59 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🤖 AI-Powered GitLab CI/CD Automation Platform

Transform your DevOps workflow with natural language-driven GitLab CI/CD automation powered by AI agents and Google Cloud.

🚀 Overview

Agentic CI/CD is a cutting-edge DevOps automation platform that revolutionizes GitLab CI/CD pipeline management through natural language processing and AI-powered multi-agent systems.

This enterprise-grade solution enables developers and DevOps engineers to:

  • Automate complex CI/CD workflows using simple English commands
  • Generate production-ready pipelines with intelligent code generation
  • Deploy to cloud platforms (AWS, GCP, Azure) automatically
  • Manage GitLab repositories through conversational AI
  • Create merge requests and handle code reviews seamlessly

✨ Key Features

🔐 Secure Authentication

  • GitLab OAuth 2.0 integration with secure token management
  • Session-based authentication with automatic cleanup
  • Role-based access control for enterprise environments

🤖 AI-Powered Multi-Agent System

  • Intelligent planning agent that breaks down complex tasks
  • Code generation agent for CI/CD pipeline creation
  • Testing and validation agent with automatic error correction
  • Execution agent for GitLab operations and deployments

🔄 Smart Retry Logic

  • Automatic code regeneration based on test failures
  • Intelligent error handling with context-aware fixes
  • Maximum retry limits to prevent infinite loops
  • Real-time feedback on pipeline creation progress

🎯 Natural Language Interface

  • Conversational AI for DevOps tasks
  • Context-aware responses with detailed explanations
  • Multi-language support for global teams
  • Voice-to-text integration ready

☁️ Cloud Platform Support

  • AWS deployment with CloudFormation/Terraform
  • Google Cloud Platform integration
  • Azure DevOps compatibility
  • Kubernetes deployment automation

🏗️ Architecture

Frontend (React + TypeScript)

  • Modern React 19 with hooks and functional components
  • TypeScript for type safety and better development experience
  • Tailwind CSS for responsive design
  • Vite for fast development and building
  • Real-time chat interface with WebSocket-like experience

Backend (Node.js + Express)

  • Express.js RESTful API with TypeScript
  • LangGraphJS for multi-agent orchestration
  • Google Gemini AI for natural language processing
  • Session management with automatic cleanup
  • Rate limiting and security middleware

GitLab MCP Server

  • Model Context Protocol implementation
  • GitLab API wrapper with comprehensive operations
  • Tool abstraction layer for agent interactions
  • Session-based token management
  • Real-time streaming with Server-Sent Events

🚀 Quick Start

Prerequisites

  • Node.js 18+ and npm
  • GitLab account with API access
  • Google Cloud account (for Gemini AI)

1. Clone and Setup

git clone https://github.com/your-org/agentic-cicd.git
cd agentic-cicd

2. Frontend Setup

cd CICD-Agent-Frontend
npm install

Create .env file:

VITE_BACKEND_URL=https://your-backend-url.onrender.com
VITE_GITLAB_CLIENT_ID=your_gitlab_client_id
VITE_REDIRECT_URI=https://your-frontend-url.vercel.app/oauth/callback
npm run dev

3. Backend Setup

cd CICD-Agent-Backend
npm install

Create .env file:

GITLAB_CLIENT_ID=your_gitlab_client_id
GITLAB_CLIENT_SECRET=your_gitlab_client_secret
GITLAB_REDIRECT_URI=https://your-frontend-url.vercel.app/oauth/callback
SUPABASE_URL=your_supabase_url
SUPABASE_KEY=your_supabase_key
GOOGLE_API_KEY=your_gemini_api_key
npm run build
npm run start

4. MCP Server Setup

cd GitLab-MCP-Server
npm install
npm run start

📖 Usage Examples

Basic CI/CD Pipeline Creation

"Set up a CI/CD pipeline for my React app that runs tests on push and deploys to Vercel"

Advanced Kubernetes Deployment

"Create a GitLab CI pipeline that builds a Docker image, pushes to ECR, and deploys to EKS cluster"

Multi-Environment Setup

"Set up staging and production environments with automated testing and blue-green deployment"

Security Scanning Integration

"Add security scanning with SonarQube and container vulnerability scanning to my pipeline"

🔧 Configuration

GitLab OAuth Setup

  1. Create a new OAuth application in GitLab
  2. Set redirect URI to your frontend callback URL
  3. Configure scopes: read_user api
  4. Add client ID and secret to environment variables

Google Cloud Setup

  1. Enable Gemini AI API in Google Cloud Console
  2. Create API key with appropriate permissions
  3. Set billing account for API usage
  4. Add API key to backend environment variables

Deployment Configuration

  • Frontend: Deploy to Vercel, Netlify, or AWS S3
  • Backend: Deploy to Render, Heroku, or AWS EC2
  • MCP Server: Deploy to Render or Google Cloud Run

🛠️ API Reference

Authentication Endpoints

POST /api/oauth/callback
GET /api/session/:sessionId/status
DELETE /api/session/:sessionId

Chat Endpoints

POST /api/chat

Health Check

GET /api/health

🔒 Security Features

  • OAuth 2.0 secure authentication flow
  • Session management with automatic expiration
  • Token validation on every request
  • CORS protection with whitelisted origins
  • Rate limiting to prevent abuse
  • Input validation and sanitization

📊 Performance

  • Sub-second response times for simple queries
  • Intelligent caching for repeated operations
  • Parallel agent execution for complex tasks
  • Automatic retry logic with exponential backoff
  • Real-time progress updates via WebSocket

🤝 Contributing

We welcome contributions! Please see our Contributing Guidelines for details.

Development Setup

# Install dependencies
npm install

# Run tests
npm test

# Start development servers
npm run dev:all

Code Style

  • TypeScript for all new code
  • ESLint and Prettier for formatting
  • Conventional commits for commit messages
  • Jest for unit testing

📈 Roadmap

  • Multi-cloud deployment support
  • Advanced security scanning integration
  • Team collaboration features
  • Mobile app development
  • Enterprise SSO integration
  • Advanced analytics dashboard
  • Custom agent development framework
  • API rate limiting improvements

Built with ❤️ by the Agentic CI/CD Team

Transform your DevOps workflow with AI-powered automation today!

About

Agentic DevOps for GitLab: LLM-driven pipeline generation, validation loop, and PR creation. React + Node + MCP.

Topics

Resources

Stars

Watchers

Forks

Contributors