Code Monkey home page Code Monkey logo

torrent-streaming's Introduction

๐Ÿฟ Torrent Streaming

Watch video torrents online. Streams them directly to your browser.

Preview

Getting Started

cp client/.env.example client/.env
cp server/.env.example server/.env

npm install
npm start

CLI Scripts

# Add an email to the list of authorised emails
npm --prefix server run add-authorised-email [email protected]

# Add and update streams in database from YTS API
npm --prefix server run update-movies

Production

##################################
# Build and run client container #
##################################
DOCKER_BUILDKIT=1 docker build client \
  --rm \
  -f client/Dockerfile \
  -t torrent-streaming/client \
  --build-arg NODE_ENV=production \
  --build-arg PORT=8080 \
  --build-arg API_URL=http://localhost:3000

docker run --rm -p 8080:8080 torrent-streaming/client

##################################
# Build and run server container #
##################################
DOCKER_BUILDKIT=1 docker build server \
  --rm \
  -f server/Dockerfile \
  -t torrent-streaming/server \
  --build-arg NODE_ENV=production \
  --build-arg PORT=3000 \
  --build-arg API_URL=http://localhost:3000 \
  --build-arg APP_URL=http://localhost:8080 \
  --build-arg CORS_ORIGINS=http://localhost:3000,http://localhost:8080 \
  --build-arg BCRYPT_ROUNDS=12 \
  --build-arg DATABASE_HOST=127.0.0.1 \
  --build-arg DATABASE_NAME=torrent-streaming \
  --build-arg DATABASE_DIALECT=sqlite \
  --build-arg DATABASE_USERNAME=torrent-streaming \
  --build-arg DATABASE_PASSWORD=secret \
  --build-arg DATABASE_STORAGE=.cache/database.sqlite \
  --build-arg JWT_SECRET=secret \
  --build-arg EMAIL_PREVIEW=true \
  --build-arg EMAIL_SEND=false \
  --build-arg [email protected] \
  --build-arg EMAIL_SMTP_HOST=smtp.sendgrid.net \
  --build-arg EMAIL_SMTP_PORT=587 \
  --build-arg EMAIL_SMTP_USERNAME=apikey \
  --build-arg EMAIL_SMTP_PASSWORD=secret

docker run --rm -p 3000:3000 torrent-streaming/server

torrent-streaming's People

Contributors

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