Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 

Repository files navigation

🚀 DevOps Control Panel Dashboard

A lightweight, production-quality web dashboard for managing Docker containers and Kubernetes resources through a clean, professional interface.

Node.js Docker Kubernetes Terraform


📋 Features

Feature Description
Dashboard Overview of containers, pods, and deployments with live stats
Container Control Start, stop, restart Docker containers; view logs
Kubernetes Control Get pods, scale deployments, restart/delete pods
Live Logs Real-time command output display
Professional UI Clean, AWS/GitHub-style dashboard with metallic blue theme

🏗️ Architecture

project/
├── frontend/           # Static HTML/CSS/JS dashboard
│   ├── index.html
│   ├── styles.css
│   └── app.js
├── backend/            # Node.js Express API server
│   ├── server.js
│   └── package.json
├── k8s/                # Kubernetes manifests
│   ├── deployment.yaml
│   └── service.yaml
├── terraform/          # AWS infrastructure
│   ├── main.tf
│   ├── variables.tf
│   └── outputs.tf
├── Dockerfile
├── Jenkinsfile
└── README.md

🚀 Quick Start

Prerequisites

  • Node.js 16+
  • Docker (for container management)
  • kubectl (for Kubernetes management)

1. Local Development

# Install dependencies
cd backend
npm install

# Start the server
npm start

Open http://localhost:3000 in your browser.

2. Docker Deployment

# Build the image
docker build -t devops-panel .

# Run (mount Docker socket for container management)
docker run -d \
  --name devops-panel \
  -p 3000:3000 \
  -v /var/run/docker.sock:/var/run/docker.sock \
  devops-panel

Open http://localhost:3000

3. Kubernetes Deployment

# Apply manifests
kubectl apply -f k8s/deployment.yaml
kubectl apply -f k8s/service.yaml

# Access via NodePort
# http://<node-ip>:30080

4. Terraform (AWS EC2)

cd terraform

# Initialize
terraform init

# Plan
terraform plan -var="key_name=your-key-pair"

# Apply
terraform apply -var="key_name=your-key-pair"

# Get the URL
terraform output panel_url

5. Jenkins CI/CD

Add the Jenkinsfile to your repository. The pipeline will:

  1. Build the Docker image
  2. Run the container
  3. Optionally deploy to Kubernetes

🎨 UI Design

  • Color Theme: White (#FFFFFF) + Metallic Blue (#5DADE2)
  • Style: Rounded cards, soft shadows, minimalist layout
  • Features: Status indicators (green/red), hover effects, toast notifications
  • Responsive: Works on desktop and mobile

📡 API Endpoints

Method Endpoint Description
GET /api/docker/containers List all containers
POST /api/docker/start/:id Start a container
POST /api/docker/stop/:id Stop a container
POST /api/docker/restart/:id Restart a container
GET /api/docker/logs/:id Get container logs
GET /api/k8s/pods List all pods
GET /api/k8s/deployments List all deployments
POST /api/k8s/scale Scale a deployment
POST /api/k8s/restart/:pod Restart a pod
DELETE /api/k8s/pod/:pod Delete a pod
GET /api/system/info System information

⚡ Performance

  • Memory usage: < 50MB (Node.js process)
  • Docker image: ~80MB (Alpine-based)
  • K8s resource limits: 128Mi memory, 100m CPU
  • Auto-refresh interval: 30 seconds

📄 License

MIT License

About

A lightweight, production-quality web dashboard for managing Docker containers and Kubernetes resources through a clean, professional interface.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages