{"id":15176629,"url":"https://github.com/hanyhm/vidly","last_synced_at":"2026-02-28T18:03:01.050Z","repository":{"id":252450854,"uuid":"840452763","full_name":"hanyhm/vidly","owner":"hanyhm","description":"DevOps project to build complete pipeline","archived":false,"fork":false,"pushed_at":"2024-08-10T09:45:37.000Z","size":35878,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-22T18:50:13.573Z","etag":null,"topics":["actions","ansible","docker","dockerhub","ec2-instances","github","grafana","jenkins","k8s","prometheus","terraform"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/hanyhm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","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}},"created_at":"2024-08-09T18:33:16.000Z","updated_at":"2024-08-10T09:45:40.000Z","dependencies_parsed_at":"2024-10-11T04:41:00.131Z","dependency_job_id":"5cf73a79-449b-448a-8978-ccd730924e9e","html_url":"https://github.com/hanyhm/vidly","commit_stats":{"total_commits":12,"total_committers":1,"mean_commits":12.0,"dds":0.0,"last_synced_commit":"d851492f1fd88c00edb28d41573eeff2bd1ada87"},"previous_names":["hanyhm/vidly"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/hanyhm/vidly","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hanyhm%2Fvidly","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hanyhm%2Fvidly/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hanyhm%2Fvidly/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hanyhm%2Fvidly/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hanyhm","download_url":"https://codeload.github.com/hanyhm/vidly/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hanyhm%2Fvidly/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29946463,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-28T17:57:52.716Z","status":"ssl_error","status_checked_at":"2026-02-28T17:57:31.974Z","response_time":90,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: 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":["actions","ansible","docker","dockerhub","ec2-instances","github","grafana","jenkins","k8s","prometheus","terraform"],"created_at":"2024-09-27T13:22:15.933Z","updated_at":"2026-02-28T18:03:01.029Z","avatar_url":"https://github.com/hanyhm.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Vidly DevOps Project\n\n## Introduction\n\nThis project demonstrates a comprehensive DevOps pipeline for the Vidly application, a video rental platform. It showcases the implementation of modern DevOps practices and tools, focusing on automation, continuous integration, continuous deployment, and monitoring.\n\nThe pipeline is designed to streamline the development process, ensure code quality, enable rapid and reliable deployments, and provide robust monitoring capabilities.\n\n## Project Scope\n\nThis project encompasses:\n\n1. Source Code Management using GitHub\n2. Containerization of the application using Docker\n3. Continuous Integration (CI) using GitHub Actions\n4. Container Registry management with Docker Hub\n5. Continuous Deployment (CD) using Jenkins\n6. Orchestration with Kubernetes\n7. Monitoring and observability with Prometheus and Grafana\n\n## Architecture\n\n\u003cimg src=\"./diagram.png\" alt=\"Project Diagram\" width=\"700\" height=\"400\"\u003e\n\nThe Vidly application consists of three main components:\n\n1. Frontend: A React-based web application\n2. Backend: A Node.js API server\n3. Database: MongoDB for data storage\n\nThese components are containerized and deployed to a Kubernetes cluster. The entire system is monitored using Prometheus and Grafana.\n\n\n\n## Technologies Used\n\n- Version Control: GitHub\n- Programming Languages: JavaScript (Node.js, React)\n- Containerization: Docker\n- CI/CD: GitHub Actions, Jenkins\n- Orchestration: Kubernetes\n- Monitoring: Prometheus, Grafana\n- Database: MongoDB\n\n\n## Project Structure\n\n```bash\nvidly/\n├── frontend/\n│   ├── Dockerfile\n│   └── ... (React app files)\n├── backend/\n│   ├── Dockerfile\n│   └── ... (Node.js app files)\n├── k8s/\n│   ├── frontend-deployment.yaml\n│   ├── backend-deployment.yaml\n│   ├── mongodb-deployment.yaml\n│   ├── prometheus-config.yaml\n│   └── grafana-deployment.yaml\n├── .github/\n│   └── workflows/\n│       └── ci.yml\n├── Jenkinsfile\n└── README.md\n```\n\n## CI/CD Pipeline\n\n1. **Code Commit**: Developers push code to the GitHub repository.\n2. **Continuous Integration**: \n   - GitHub Actions triggers automated tests for both frontend and backend.\n   - If tests pass, Docker images are built and pushed to Docker Hub.\n3. **Continuous Deployment**:\n   - Jenkins pulls the latest images and deploys to the Kubernetes cluster.\n4. **Monitoring**:\n   - Prometheus continuously collects metrics from the deployed applications.\n   - Grafana provides visualization of these metrics.\n\n## Setup Instructions\n\n### 1. Clone the repository:\n```bash\ngit clone https://github.com/hanyhm/vidly.git\n```\n\n### 2. Set up Docker Hub credentials in GitHub Secrets:\n```bash\n- DOCKERHUB_USERNAME\n- DOCKERHUB_PASSWORD\n```\n\n### 3. Install Required Software:\na. Install Jenkins:\n```bash\nwget -q -O - https://pkg.jenkins.io/debian-stable/jenkins.io.key | sudo apt-key add -\nsudo sh -c 'echo deb http://pkg.jenkins.io/debian-stable binary/ \u003e /etc/apt/sources.list.d/jenkins.list'\nsudo apt update\nsudo apt install jenkins\n```\nb. Install Docker:\n```bash\nsudo apt install docker.io\nsudo usermod -aG docker jenkins\nsudo usermod -aG docker $USER\n```\n\nc. Install Minikube:\n```bash\ncurl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64\nsudo install minikube-linux-amd64 /usr/local/bin/minikube\n```\n\nd. Install kubectl:\n```bash\ncurl -LO \"https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl\"\nsudo install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl\n```\n\n### 4. Configure Jenkins:\na. Open Jenkins in your browser (typically http://localhost:8080)\nb. Install suggested plugins\nc. Create an admin user\nd. Install additional plugins: Docker Pipeline, Kubernetes CLI\ne. Configure Jenkins to use Docker as the build agent\n\n#### Set up Jenkins Credentials:\na. Go to \"Manage Jenkins\" \u003e \"Manage Credentials\"\nb. Add Docker Hub credentials (Username with password)\nc. Add GitHub credentials if your repository is private\n\n#### Create Jenkins Pipeline:\na. Click \"New Item\"\nb. Choose \"Pipeline\" and give it a name\nc. In the Pipeline section, choose \"Pipeline script from SCM\"\nd. Set SCM to Git and provide your repository URL\ne. Set the branch to */main\nf. Set the Script Path to \"jenkins/Jenkinsfile\"\n\n#### Configure Minikube for Jenkins:\na. SSH into your Jenkins server\nb. Switch to the jenkins user: \n```bash \nsudo su - jenkins\n```\nc. Start Minikube: \n```bash \nminikube start --driver=docker\n```\nd. Stop Minikube:\n```bash\n minikube stop\n ```\n\n#### Adjust Permissions:\n```bash\nsudo chmod 666 /var/run/docker.sock\nsudo usermod -aG docker jenkins\n```\n\n#### Restart Jenkins:\n```bash\nsudo systemctl restart jenkins\n```\n\n### 5. Create a Jenkins job that uses the Jenkinsfile in the repo.\n\n### 6. Set up a GitHub webhook to trigger the Jenkins job on push to the main branch.\n\n### 7. Deploy Prometheus and Grafana:\n```bash\nkubectl apply -f k8s/prometheus-config.yaml\nkubectl apply -f k8s/grafana-deployment.yaml\n```\n\n8. Access Grafana and set up dashboards to visualize your application metrics.\n\n## Usage\n\n- Push changes to the main branch to trigger the CI/CD pipeline.\n- Monitor the GitHub Actions workflow and Jenkins job for deployment status.\n- Access the application.\n- View application metrics and performance in Grafana.\n\n## Monitoring\n\n- Prometheus is set up to scrape metrics from all Kubernetes pods.\n- Grafana provides visualization of these metrics.\n- Default dashboards include:\n- Kubernetes cluster overview\n- Node.js application metrics\n- MongoDB performance metrics\n\n\n## Contributing\n\nPlease read [CONTRIBUTING.md](CONTRIBUTING.md) for details on our code of conduct, and the process for submitting pull requests.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE.md](LICENSE) file for details.\n\n**\n## Testing \n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhanyhm%2Fvidly","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhanyhm%2Fvidly","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhanyhm%2Fvidly/lists"}