Coder Social home page Coder Social logo

camharris / livetube Goto Github PK

View Code? Open in Web Editor NEW
6.0 2.0 0.0 468 KB

A project submission for the eth.global web3 hackathon that uses Livepeer (for video streaming) and Filecoin/IPFS (for file storage)

JavaScript 64.05% Dockerfile 7.34% Python 28.61%

livetube's Introduction

LiveTube

A personal video tube site built on top of Filecoin, Textile, and Livepeer

logo

liveTube is a tube site that allows videos to be uploaded to a collection within slate.host and these videos are then deployed in the web app frontend. Once the user chooses a video to stream in the frontend, a backend process is kicked off where a stream is created via ffmpeg pulling the video file from the ipfs gateway and sending it to Livepeer ingest endpoint.

Technologies and how things work

  • NextJS: The frontend is a simple web app based on next.js
  • Python/FastAPI: The api is a python fastapi app that listens for POST requests in order to know which file cid's to create video streams for. Once the request comes in a stream is created in the Livepeer platform via the Livepeer api. The api can be invoked directly via docs page located at http://localhost:8000/docs. fastAPI/docs
  • Slate: Slate is used for uploading and storing videos and it's api is used for querying the video information. Slate is a file sharing network built on top of Textile and Filecoin
  • Livepeer: Livepeer is used for creating video streams and transcoding videos for various device sizes. Livepeer is a decentralized video streaming network built on the Ethereum blockchain.
  • ffmpeg: FFmpeg is used for streaming the video from the ipfs gateway to Livepeer's video ingestion endpoint.

How to run:

  1. Clone repo
git clone [email protected]:camharris/livetube.git
~~
cd livetube
  1. Create a .env.local file in the ffmpeg_api directory with your Livepeer api key
echo LIVEPEER_API_KEY=YOUR_API_KEY > ffmpeg_api/.env.local
  1. Create a .env.local file in the livetube-app directory with your slate api key and api address (the api address should be 'api')
echo NEXT_PUBLIC_SLATE_API_KEY=YOUR_SLATE_API_KEY > livetube-app/.env.local
echo NEXT_PUBLIC_LOCAL_API=api:8000 >> livetube-app/.env.local
  1. Build containers and then docker-compose
docker-compose build
docker-compose up

Issues/TODO

  • Video streaming hasn't been implemented into the web app as of yet. however streams can be view/tested using THEOplayer
  • The video page of the UI doesn't talk to the ffmpeg_api yet.

livetube's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

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