GithubHelp home page GithubHelp logo

hiteshgarg14 / video-utility-platform-backend Goto Github PK

View Code? Open in Web Editor NEW
11.0 1.0 5.0 279 KB

A NodeJS application to upload, watch and stream live videos.

TypeScript 97.07% JavaScript 2.93%
nodejs types expressjs fluent-ffmpeg node-media-server bull ffmpeg busboy rtmp websocket

video-utility-platform-backend's Introduction

NodeJS Video Utility Platform

A NodeJS application to upload, watch and stream live videos.

Installation

  • Clone the repository and run following commands:

    • npm install
    • touch .env
  • Configure following environment variables in .env file:

    • NODE_ENV : development / staging / production
    • PORT : Port to run the app. (Default: 4000)
    • DB_USERNAME : Postgres database username
    • DB_PASSWORD : Postgres database password
    • DB_NAME : Postgres database name
    • DB_HOST : Postgres database host
    • DB_PORT : Postgres database port
    • REDIS_HOST : Redis database host
    • REDIS_PORT : Redis database port
    • REDIS_PASSWORD : Redis database password
    • NMS_RTMP_PORT : Node media server RTMP port.(Default: 1935)
    • NMS_HTTP_PORT : Node media server HTTP port. (Default: 8001)
    • NMS_HTTP_MEDIA_ROOT : Root path of video files directory used by Node media server. (Default: /uploads/liveMedia)
    • VIDEO_UPLOAD_BUFFER_SIZE : Buffer size for uploading videos in chunks. (Default: 2 MiB)
    • VIDEO_UPLOAD_MAX_FILE_SIZE : Max video file size to be uploaded. (Default: 10 MiB)
    • SENTRY_DSN (optional): DSN Url of sentry for error tracking
    • WS_VIDEO_UPLOAD_BUFFER_SIZE : Buffer size for uploading videos using websocket. (Default: 10 MiB)
    • WS_VIDEO_UPLOAD_CHUNK_SIZE : Chunk size for uploading videos using websocket. (Default: 2 MiB)
    • MEDIA_UPLOAD_PATH : Path to save uploaded media files. (Default: /uploads)
  • Make sure that database has been created with same name as DB_NAME mentioned in .env file.

  • Run following commands

    • npx sequelize-cli db:migrate
    • npm start

Built With

  • ExpressJS : Fast, unopinionated, minimalist web framework for Node.js
  • Sequelize : An easy-to-use multi SQL dialect ORM for Node.js
  • Node Media Server : A Node.js implementation of RTMP/HTTP-FLV/WS-FLV/HLS/DASH/MP4 Media Server
  • Typescript : TypeScript is a typed superset of JavaScript that compiles to plain JavaScript
  • node-fluent-ffmpeg : A fluent API to FFMPEG
  • connect-busboy : Connect middleware for busboy (A streaming parser for HTML form data for node.js)

Todos

  • Write tests for all APIs, Jobs, Middlewares

  • Improve latency in live video streamings

  • Move uploads folder to blob storage

  • Add user management and authentication functionalities

  • Write API, Websocket documentation

  • Handle duplicate video upload by name

  • Complete all inline TODO comments

  • ...

video-utility-platform-backend's People

Contributors

dependabot[bot] avatar hiteshgarg14 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  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.