Coder Social home page Coder Social logo

zineddinebk09 / mp4-to-mp3-converter-with-microservices-architecture-python-flask-mysql-k8s-and-docker Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 361 KB

This is a simple MP4 to MP3 converter using Python, Flask, MySQL, K8s, and Docker. The application is a simple web application that allows users to upload an MP4 file and convert it to an MP3 file. The application will be based on a **Microservices Architecture** and will be deployed on **Kubernetes**.

Python 82.41% Dockerfile 17.59%

mp4-to-mp3-converter-with-microservices-architecture-python-flask-mysql-k8s-and-docker's Introduction

MP4 to MP3 Converter with Python, Flask, MySQL, K8s, and Docker

Table of Contents ๐Ÿ“‹

Introduction ๐Ÿ“

This is a simple MP4 to MP3 converter using Python, Flask, MySQL, K8s, and Docker. The application is a simple web application that allows users to upload an MP4 file and convert it to an MP3 file. The application will be based on a Microservices Architecture and will be deployed on Kubernetes.

Technologies ๐Ÿ› ๏ธ

  • Python
  • Flask
  • MySQL
  • K8s
  • Docker

Development Environment ๐Ÿ› ๏ธ

  • Ubuntu 22.04
  • Python 3.10.12
  • Flask 3.0.2
  • MySQL 8.0.36
  • K8s 1.22.2

Architecture ๐Ÿ—๏ธ

The application will be based on a Microservices Architecture. The application will consist of the following services:

  • Frontend Service: This service will be responsible for handling the user interface. It will be a simple web application that allows users to upload an MP4 file and convert it to an MP3 file.
  • API Gateway: This is the entry point for the system. It will be responsible for routing requests to the appropriate services.
  • Auth service: This service will be responsible for handling user authentication and authorization.
  • Auth DB: This service will be responsible for storing user information.
  • Queue Service: This service will use RabbitMQ to store messages that need to be processed by the system. so when a user uploads an MP4 file, a message will be sent to the queue, and the video to mp3 service will process the message (which contains the video id in MongoDB) and convert the MP4 file to an MP3 file.
  • Storage DB: This service (Mongo GridFS) will be responsible for storing the MP4 and MP3 files.
  • Video to mp3 service: This service will be responsible for converting the MP4 file to an MP3 audio file.
  • Notification service: This service will be responsible for sending notifications to users.
  • K8s: All the above services will be deployed on a Kubernetes cluster.
  • Architecture

Deployment ๐Ÿš€

The application will be deployed on Kubernetes. The application will be deployed as a set of Docker containers, with each service running in its own container. The application will be deployed on a Kubernetes cluster, with each service running as a Kubernetes deployment.

Setup ๐Ÿ› ๏ธ

The first step is to install the required dependencies. The application requires the following dependencies:

Python ๐Ÿ

  • Flask: pip install flask
  • Flask-MySQL: pip install flask-mysql
  • Flask-Uploads: pip install flask-uploads

MySQL ๐Ÿฌ

  • MySQL: sudo apt-get install mysql-server
  • Tutorial: https://www.digitalocean.com/community/tutorials/how-to-install-mysql-on-ubuntu-22-04
  • Run the following commands to create the database, user, and the users table: mysql -uroot < init.sql

RabbitMQ ๐Ÿฐ

  • RabbitMQ: sudo apt-get install rabbitmq-server

K8s ๐Ÿšข

  • Minikube: https://minikube.sigs.k8s.io/docs/start/
  • K9s: https://github.com/derailed/k9s

Docker ๐Ÿณ

  • Docker: https://docs.docker.com/engine/install/ubuntu/

The next step is to clone the repository and build the Docker images for the services. The repository contains a Dockerfile for each service, which can be used to build the Docker images. The Dockerfile for each service is located in the root directory of the repository.

Conclusion ๐ŸŽ‰

This is a simple MP4 to MP3 converter using Python, Flask, MySQL, K8s, and Docker. The application is a simple web application that allows users to upload an MP4 file and convert it to an MP3 file. The application is based on a Microservices Architecture and is deployed on Kubernetes.

mp4-to-mp3-converter-with-microservices-architecture-python-flask-mysql-k8s-and-docker's People

Contributors

zineddinebk09 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.