# learningtigris/swiggy-devops-cicd-pipeline architecture

> Architecture diagram of the GitHub repository learningtigris/swiggy-devops-cicd-pipeline, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-15). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/learningtigris/swiggy-devops-cicd-pipeline
- Repository: https://github.com/learningtigris/swiggy-devops-cicd-pipeline

## Overview

This repository combines a static Swiggy-style restaurant discovery frontend with a documented AWS CI/CD deployment project. The frontend entry point mounts a page composed of navigation, offers and food categories, restaurant collections, city/cuisine links, and a footer; restaurant and offer content is rendered from hard-coded markup. The README describes a separate Jenkins-led build, analysis, scan, image-publishing, and deployment workflow, with Terraform provisioning AWS infrastructure. Pipeline wiring is shown by the README, not sampled Jenkins or Terraform source.

Main entry points: [`src/App.js`](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/App.js) (Page composition), [`jenkins/Jenkinsfile`](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/jenkins/Jenkinsfile) (Jenkins pipeline), [`src/index.js`](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/index.js) (React entry), [`src/Components/OffersBanner.jsx`](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/OffersBanner.jsx) (Offers and categories)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Restaurant frontend"]
  node_react_entry["React entry<br/>[index.js]"]
  node_app_shell["Page composition<br/>[App.js]"]
  node_navigation["Location navigation<br/>[Navigate.jsx]"]
  node_offers["Offers and categories<br/>[OffersBanner.jsx]"]
  node_chains["Restaurant chains"]
  node_online_list["Delivery listings"]
  node_city_links["City and cuisine links<br/>[BestRest.jsx]"]
  node_footer["App and company footer<br/>[Footer.jsx]"]
end

subgraph group_pipeline["CI/CD pipeline"]
  node_jenkins["Jenkins pipeline"]
  node_quality_gate["Quality gate"]
  node_docker_image["Docker image build"]
end

subgraph group_infrastructure["Cloud infrastructure"]
  node_terraform["Terraform provisioning<br/>[main.tf]"]
  node_deployed_app["Hosted application"]
end

subgraph group_integrations["External services"]
  node_media(("Swiggy media CDN"))
  node_github(("GitHub source"))
  node_sonar["SonarQube analysis"]
  node_trivy["Trivy security scan"]
  node_dockerhub["DockerHub registry"]
  node_aws["AWS EC2 and network"]
end

node_visitor(("Site visitor"))

node_visitor -->|"opens"| node_react_entry
node_react_entry -->|"renders"| node_app_shell
node_app_shell -->|"renders"| node_navigation
node_app_shell -->|"renders"| node_offers
node_app_shell -->|"renders"| node_chains
node_app_shell -->|"renders"| node_online_list
node_app_shell -->|"renders"| node_city_links
node_app_shell -->|"renders"| node_footer
node_offers -->|"loads images"| node_media
node_online_list -->|"loads images"| node_media
node_chains -->|"loads images"| node_media
node_github -->|"triggers pipeline"| node_jenkins
node_jenkins -->|"runs analysis"| node_sonar
node_jenkins -->|"validates results"| node_quality_gate
node_jenkins -->|"runs scans"| node_trivy
node_jenkins -->|"builds image"| node_docker_image
node_jenkins -->|"pushes image"| node_dockerhub
node_terraform -->|"provisions infrastructure"| node_aws
node_jenkins -->|"deploys container"| node_aws
node_dockerhub -->|"supplies image"| node_deployed_app

click node_react_entry "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/index.js"
click node_app_shell "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/App.js"
click node_navigation "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/Navigate.jsx"
click node_offers "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/OffersBanner.jsx"
click node_chains "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/RestaurentChain.jsx"
click node_online_list "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/RestaurentOnline.jsx"
click node_city_links "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/BestRest.jsx"
click node_footer "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/Footer.jsx"
click node_jenkins "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/jenkins/Jenkinsfile"
click node_quality_gate "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/jenkins/Jenkinsfile"
click node_docker_image "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/docker/Dockerfile"
click node_terraform "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/terraform/main.tf"
click node_deployed_app "https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/docker/Dockerfile"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_react_entry,node_app_shell,node_navigation,node_offers,node_chains,node_online_list,node_city_links,node_footer toneBlue
class node_jenkins,node_quality_gate,node_docker_image toneAmber
class node_terraform,node_deployed_app toneMint
class node_media,node_github,node_sonar,node_trivy,node_dockerhub,node_aws toneRose
class node_visitor toneIndigo
```

## Components

### Restaurant frontend

- [React entry](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/index.js): `src/index.js`
- [Page composition](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/App.js): `src/App.js`
- [Location navigation](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/Navigate.jsx): `src/Components/Navigate.jsx`
- [Offers and categories](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/OffersBanner.jsx): `src/Components/OffersBanner.jsx`
- [Restaurant chains](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/RestaurentChain.jsx): `src/Components/RestaurentChain.jsx`
- [Delivery listings](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/RestaurentOnline.jsx): `src/Components/RestaurentOnline.jsx`
- [City and cuisine links](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/BestRest.jsx): `src/Components/BestRest.jsx`
- [App and company footer](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/src/Components/Footer.jsx): `src/Components/Footer.jsx`

### CI/CD pipeline

- [Jenkins pipeline](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/jenkins/Jenkinsfile): `jenkins/Jenkinsfile`
- [Quality gate](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/jenkins/Jenkinsfile): `jenkins/Jenkinsfile`
- [Docker image build](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/docker/Dockerfile): `docker/Dockerfile`

### Cloud infrastructure

- [Terraform provisioning](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/terraform/main.tf): `terraform/main.tf`
- [Hosted application](https://github.com/learningtigris/swiggy-devops-cicd-pipeline/blob/main/docker/Dockerfile): `docker/Dockerfile`

### External services

- **Swiggy media CDN**
- **GitHub source**
- **SonarQube analysis**
- **Trivy security scan**
- **DockerHub registry**
- **AWS EC2 and network**

### Other components

- **Site visitor**

## Connections

- Site visitor → React entry: opens
- React entry → Page composition: renders (evidence: `src/index.js`)
- Page composition → Location navigation: renders (evidence: `src/App.js`)
- Page composition → Offers and categories: renders (evidence: `src/App.js`)
- Page composition → Restaurant chains: renders (evidence: `src/App.js`)
- Page composition → Delivery listings: renders (evidence: `src/App.js`)
- Page composition → City and cuisine links: renders (evidence: `src/App.js`)
- Page composition → App and company footer: renders (evidence: `src/App.js`)
- Offers and categories → Swiggy media CDN: loads images (evidence: `src/Components/OffersBanner.jsx`)
- Delivery listings → Swiggy media CDN: loads images (evidence: `src/Components/RestaurentOnline.jsx`)
- Restaurant chains → Swiggy media CDN: loads images (evidence: `src/Components/RestaurentChain.jsx`)
- GitHub source → Jenkins pipeline: triggers pipeline (evidence: `README.md`)
- Jenkins pipeline → SonarQube analysis: runs analysis (evidence: `README.md`)
- Jenkins pipeline → Quality gate: validates results (evidence: `README.md`)
- Jenkins pipeline → Trivy security scan: runs scans (evidence: `README.md`)
- Jenkins pipeline → Docker image build: builds image (evidence: `README.md`)
- Jenkins pipeline → DockerHub registry: pushes image (evidence: `README.md`)
- Terraform provisioning → AWS EC2 and network: provisions infrastructure (evidence: `README.md`)
- Jenkins pipeline → AWS EC2 and network: deploys container (evidence: `README.md`)
- DockerHub registry → Hosted application: supplies image (evidence: `README.md`)
