Skip to content

Latest commit

 

History

History
92 lines (72 loc) · 2.63 KB

File metadata and controls

92 lines (72 loc) · 2.63 KB

Kue: Devops Blogging Site

Welcome to Kue, a cloud-native devops blogging platform. This project demonstrates modern DevOps practices using Kuernetes, Terraform, Flask, and Docker.

Features

  • News Blogging: Create, read, and manage news articles.
  • Cloud-Native: Built for scalability and reliability.
  • Containerized: All components run in Docker containers.
  • Infrastructure as Code: Automated provisioning with Terraform.
  • Orchestrated Deployment: Managed using EKSCluster.

Tech Stack

  • Flask: Backend web framework (Python)
  • Docker: Containerization of application components
  • Kuernetes: Orchestration and scaling
  • Terraform: Infrastructure provisioning

Getting Started

  1. Clone the repository

    git clone https://github.com/utkarshkgit/Kue.git
    cd cloud_blog
  2. Provision Infrastructure

    • Configure your cloud provider credentials.
    aws configure
    • Run Terraform scripts in the infrastructure/ directory:
      cd infrastructure
      terraform init
      terraform apply
  3. Build and Push Docker Images

    docker build -t <username>/cloud_blog:latest .
    docker push <username>/cloud_blog:latest
  4. Deploy to Kuernetes with Network Load Balancer

    • Apply Kuernetes manifests with network-aware deployment:
      aws eks --region us-east-2 update-Kueconfig --name my-cluster
      cd k8s
      
      # Create database secret first
      kubectl create secret generic db-credentials \
        --from-literal=PGHOST=your-db-host \
        --from-literal=PGDATABASE=blogdb \
        --from-literal=PGUSER=your-db-user \
        --from-literal=PGPASSWORD=your-db-password \
        --from-literal=PGPORT=5432
      
      # Deploy with network load balancer
      ./deploy-network-aware.sh

    Alternative manual deployment:

    kubectl apply -f kub.yaml                    # Core application
    kubectl apply -f nginx-loadbalancer.yaml     # Nginx load balancer
    kubectl apply -f network-policy.yaml         # Network policies
    kubectl apply -f hpa.yaml                    # Auto-scaling
  5. Access the Application

    • Find the service endpoint and open it in your browser.

Project Structure

.
├── app.py            # Flask application code
├── Dockerfile        # Docker build instructions
├── k8s/              # Kuernetes manifests
├── infrastructure/   # Terraform scripts
└── README.md

License

This project is licensed under the MIT License.


Happy blogging in the cloud!