Code Monkey home page Code Monkey logo

nodetube's Introduction

NodeTube

NodeTube is an open-source YouTube alt that offers video, audio and image uploads, livestreaming and built-in monetization

A live NodeTube instance is available to interact with at https://newtube.app

You can join the open-source community actively developing NodeTube on Discord, Riot.im and Reddit


You can get an instance up instantly using one-click deployment with Heroku below:

Deploy

Running On Your Local Computer

Required Software

See instructions on installing these prerequisites for both OS X and Linux. There are also Docker instructions if that's your thing.

Once Prerequisites Are Installed

Now that the prerequisites are ready to go it's a few simple commands to get your instance up and running.

# Get the latest version of NodeTube
git clone https://github.com/mayeaux/nodetube

# Enter the nodetube folder that was just created
cd nodetube

# Install Node modules
npm install

# Then simply start your app
npm start

#If you're developing locally, you can boot the app with nodemon with:
npm run dev

And that's it! Your first user registered will automatically be an admin user and you will be able to see the admin and moderation functionality. Each additional user will be a regular user and will be able to upload video, audio or images up to 500MB.

For ease of local development I recommend using Nodemon to automatically restart the app while working on backend code.

Using ngrok

NodeTube comes with ngrok preinstalled with the setting in .env.settings to run for new instances automatically. This means that when you boot the app you will see a log come through with a link where you can access the app from the ngrok subdomain. Great you're live on the internet, that was simple!

Technical Details

NodeTube is an Express application powered by NodeJS, with MongoDB as a database, with Redis for caching and ffmpeg for converting and compressing video content. It uses Pug as a templating engine and loads process variables through the .env.settings and .env.private files.

NodeTube uses resumable.js on the frontend as a library to allow stable and resumable uploads allowing for the upload process to not be broken during a system reboot.

NodeTube has the functionality to act as an authentication app for an nginx-rtmp server which allows NodeTube to facilitate livestreaming. NodeTube also has a built in livestreaming frontend with a live chat, live viewer count and which uses hls.js to stream the files being created by nginx-rtmp

[This section is being expanded rapidly so please Watch this repo so you can easily see when more documentation is available]

Reasons To Use NodeTube

Reasons to use NodeTube as an Instance Host:

  • Built in monetization for instance administrators: Users can optionally pay a monthly fee through Stripe to gain certain privileges which are able to be adjusted by the administrator but by default allow private and unlisted uploads, an increased maximum file-size limit from 500MB to 2GB, and livestreaming capabilities
  • You can run an instance either with a cloud provider, a VPS or dedicated server or even locally using a built-in ngrok integration.
  • Follow a few short steps and get setup on top of cloud providers and run for pennies a day with built-in Heroku and BackBlaze integrations, even with little technical knowledge
  • Own your own data: data is happier when it's not in the hands of a multi-billion dollar corporation and plus Google knows enough about us already
  • Built in features to get you started on Day 1 including moderation abilities, built-in analytics, administration interface, built-in reCAPTCHA
  • Support open-source software, help decentralize and open the internet.
  • Improve your software and server administration skills
  • Build and foster a community

Reasons to use NodeTube as a Free User:

  • No email necessary for registration. Optionally add an email to have password recovery functionality
  • No ads
  • Not tracked by a multibillion dollar corporation
  • Public IP stays private, unlike some other YouTube alts
  • Upload all forms of content (video, audio, image)
  • 500 MB max upload size
  • Able to load your account with credit and support creators directly [Note: This functionality exists in the NodeTube source tube but finding a payment processor to support this/legal implications are more difficult to pull off in practice.]
  • Support open-source software, help decentralize and open the internet.
  • Engage with and help grow a community

Reasons To Use NodeTube as a Paid User:

  • Ability to monetize your account and be paid directly by the instance users [Note: This functionality exists in the NodeTube source tube but finding a payment processor to support this/legal implications are more difficult to pull off in practice.]
  • Larger upload size, up to 2GB
  • Private and unlisted uploads
  • Livestreaming
  • Plus Badge to show your support
  • Support open-source software with your hard earned money, helping out in a big way to decentralize and open the internet
  • Allow others to receive the benefits of using NodeTube as a free user including not being tracked by a multibillion dollar corporation and receiving their media ad free

Additional Info

You may also be interested in videodownloader, a video downloader that supports 110 websites and is powered by Electron and youtube-dl.

Don't forget to join the open-source community developing NodeTube on Discord, Riot.im and Reddit

Live NodeTube Instances

Domain Registrations Open Ratings Allowed
https://newtube.app Yes SFW Only
https://allwat.ch Yes SFW/NSFW/Sensitive

License

Licensed under the MIT License. © NodeTube Organization

nodetube's People

Contributors

alechash avatar bassofbass avatar bougyman avatar carlostojal avatar craigerrington avatar dependabot[bot] avatar dmdboi avatar erebor avatar lsimichael avatar mayeaux avatar mb175 avatar mxchaeltrxn avatar ralyodio avatar rosscomputerguy avatar ryochan7 avatar thomaspaulson avatar zlatanvasovic avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

nodetube's Issues

Env vars get blown away if you check out a new branch

Currently .env.settings and .env.private are ignored by Git. That means if you check out a new branch no matter what they disappear into thin air.

Apparently there is no way around this going the gitignore route:
https://stackoverflow.com/questions/37207628/git-keep-ignored-files-when-switching-branches

But I think this can be approached via this functionality:
https://stackoverflow.com/questions/9794931/keep-file-in-a-git-repo-but-dont-track-changes/50222853#50222853

Either way this is basically urgent top priority to be fixed, because this could really hurt an instance host.

Add copy buttons for the links on about

Would be helpful for users if there was a Copy To Clipboard button beside the links in the about page. Not the highest priority but would be cool. Code already exists on media.pug just need to copy it over and add something to the frontend

Add background job processor.

If the intent of this application is to be scaleable, it isn't ideal to process all the uploaded files in the main web server process. After a few (100-1000 not sure) simultaneous uploads performance may suffer handling other requests.

I've found a few options for achieving this easily:

To achieve this the code in this async block would be moved to a background job.

Terms of Service

Wondering if the terms of service was copied/generated from something specific for open source projects?

Specifically wondering if this line makes sense:

you may not ... disassemble, decompile or reverse engineer any of the software components of the Service,

'High quality' doesn't work on nodetube-1

Currently 'high quality' functionality doesn't work on nodetube-1. I think it's to do with the Backblaze implementation and frankly I think there should probably be a flag to do the conversions conditionally because with a Backblaze implementation I don't really want to support 'high quality' uploads if it's just a demo app, whereas in a real instance I would.

Example upload: https://nodetube-1.herokuapp.com/user/Koalo/lu7NVm5

Need status message after editing upload details

With the most recent update, there is no type of confirmation that an upload entry was updated successfully after clicking the Edit Upload button; I wanted to change the category for some of my videos. I thought that the submit button might have been broken but going to the page again showed that the upload entry was updated. It can be a bit confusing at first. Having some type of status message appear after submitting the form would clear up the behavior of the form.

Create a Riot/Matrix room

Many FOSS enthusiasts don't use Discord because it's proprietary. So we've got Riot/Matrix which is totally open source and decentralized. I'd recommend switching to it or at least creating a room there as well.
Cheers!

Thoughts on CI?

I always use Travis CI for my projects, easy to get up and running. I used it for my most recent Node project using Docker and AWS ELB.

add LICENSE file

The project needs a license. Have you decided which one you're gonna pick? Hopefully AGPL v3?

ngrok tunnels error out with simultaneous request limit

ngrok tunnels error out with simultaneous request limit due in my estimation to the fact that it's counting each get request for static items (an image etc) as a separate request. Need to think about a way to engineer around this if possible

Publish to Docker Hub

Server admin here on a Synology box. It'd be really really convenient for us if an image was pushed to Docker Hub for true selfhosted "one-click" deployments.

Use websocket to alert users of converting progress

Currently the pending upload functionality is quite basic. It just tells the user things are processing and to check back later. It would be pretty trivial to implement websockets to let the user have realtime updates, so that should be implemented.

error in console when uploading

A cookie associated with a cross-site resource at <URL> was set without the `SameSite` attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with `SameSite=None` and `Secure`. You can review cookies in developer tools under Application>Storage>Cookies and see more details at <URL> and <URL>.
A cookie associated with a cross-site resource at <URL> was set without the `SameSite` attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with `SameSite=None` and `Secure`. You can review cookies in developer tools under Application>Storage>Cookies and see more details at <URL> and <URL>.
A cookie associated with a cross-site resource at <URL> was set without the `SameSite` attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with `SameSite=None` and `Secure`. You can review cookies in developer tools under Application>Storage>Cookies and see more details at <URL> and <URL>.
A cookie associated with a cross-site resource at <URL> was set without the `SameSite` attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with `SameSite=None` and `Secure`. You can review cookies in developer tools under Application>Storage>Cookies and see more details at <URL> and <URL>.
A cookie associated with a cross-site resource at <URL> was set without the `SameSite` attribute. A future release of Chrome will only deliver cookies with cross-site requests if they are set with `SameSite=None` and `Secure`. You can review cookies in developer tools under Application>Storage>Cookies and see more details at <URL> and <URL>.
pJuVy0o:1 GET https://test.profullstack.com/bower_components/sweetalert2/dist/sweetalert2.css net::ERR_ABORTED 404
pJuVy0o:27 GET https://test.profullstack.com/bower_components/sweetalert2/dist/sweetalert2.js net::ERR_ABORTED 404
pJuVy0o:27 GET https://test.profullstack.com/bower_components/sweetalert2/dist/sweetalert2.js net::ERR_ABORTED 404
pJuVy0o:27 GET https://test.profullstack.com/bower_components/sweetalert2/dist/sweetalert2.js net::ERR_ABORTED 404
pJuVy0o:51 already reported 
pJuVy0o:53 
pJuVy0o:64 thing here
pJuVy0o:121 here!!!
pJuVy0o:246 null
pJuVy0o:596 Uncaught SyntaxError: Unexpected token 'var'
pJuVy0o:735 ƒ getParameterByName(name, url) {
  if (!url) url = window.location.href;
  name = name.replace(/[\[\]]/g, "\\$&");
  var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"),
    results = regex.ex…
pJuVy0o:737 here
[Violation] Added non-passive event listener to a scroll-blocking <some> event. Consider marking event handler as 'passive' to make the page more responsive. See <URL>
[Violation] Added non-passive event listener to a scroll-blocking <some> event. Consider marking event handler as 'passive' to make the page more responsive. See <URL>
[Violation] Added non-passive event listener to a scroll-blocking <some> event. Consider marking event handler as 'passive' to make the page more responsive. See <URL>
[Violation] Added non-passive event listener to a scroll-blocking <some> event. Consider marking event handler as 'passive' to make the page more responsive. See <URL>
[Violation] Added non-passive event listener to a scroll-blocking <some> event. Consider marking event handler as 'passive' to make the page more responsive. See <URL>
[Violation] Added non-passive event listener to a scroll-blocking <some> event. Consider marking event handler as 'passive' to make the page more responsive. See <URL>
[Violation] Added non-passive event listener to a scroll-blocking <some> event. Consider marking event handler as 'passive' to make the page more responsive. See <URL>
[Violation] Added non-passive event listener to a scroll-blocking <some> event. Consider marking event handler as 'passive' to make the page more responsive. See <URL>
[Violation] Added non-passive event listener to a scroll-blocking <some> event. Consider marking event handler as 'passive' to make the page more responsive. See <URL>
[Violation] Added non-passive event listener to a scroll-blocking <some> event. Consider marking event handler as 'passive' to make the page more responsive. See <URL>
plyr.js:1 Uncaught (in promise) DOMException: play() failed because the user didn't interact with the document first. https://goo.gl/xX8pDD
le @ plyr.js:1
Ye @ plyr.js:2
He @ plyr.js:2
E @ plyr.js:2
(anonymous) @ plyr.js:2
A @ plyr.js:2
(anonymous) @ pJuVy0o:757
pJuVy0o:266 /user/chovy/pJuVy0o
pJuVy0o:270 
pJuVy0o:33 GET https://test.profullstack.com/uploads/chovy/pJuVy0o.mp4 404
pJuVy0o:1 GET https://test.profullstack.com/uploads/chovy/pJuVy0o.mp4 404
mtgm.js:92 [Violation] Added synchronous DOM mutation listener to a 'DOMNodeInserted' event. Consider using MutationObserver to make the page more responsive.
(anonymous) @ mtgm.js:92
vendors~rollbar.noconflict.umd.min.bf8fe626e38d9530fbdc.js:1 Key is missing from snippet
e.<computed> @ vendors~rollbar.noconflict.umd.min.bf8fe626e38d9530fbdc.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
h @ asset_composer.5d2cd6d9613b85125812.js:1
u @ asset_composer.5d2cd6d9613b85125812.js:1
postMessage (async)
r @ asset_composer.5d2cd6d9613b85125812.js:1
p.setImmediate @ asset_composer.5d2cd6d9613b85125812.js:1
u._immediateFn @ asset_composer.5d2cd6d9613b85125812.js:1
c @ asset_composer.5d2cd6d9613b85125812.js:1
l @ asset_composer.5d2cd6d9613b85125812.js:1
s @ asset_composer.5d2cd6d9613b85125812.js:1
n @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
Promise.then (async)
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
d @ asset_composer.5d2cd6d9613b85125812.js:1
u @ asset_composer.5d2cd6d9613b85125812.js:1
$ @ asset_composer.5d2cd6d9613b85125812.js:1
B @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
h @ asset_composer.5d2cd6d9613b85125812.js:1
u @ asset_composer.5d2cd6d9613b85125812.js:1
postMessage (async)
r @ asset_composer.5d2cd6d9613b85125812.js:1
p.setImmediate @ asset_composer.5d2cd6d9613b85125812.js:1
u._immediateFn @ asset_composer.5d2cd6d9613b85125812.js:1
c @ asset_composer.5d2cd6d9613b85125812.js:1
l @ asset_composer.5d2cd6d9613b85125812.js:1
f @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
h @ asset_composer.5d2cd6d9613b85125812.js:1
u @ asset_composer.5d2cd6d9613b85125812.js:1
postMessage (async)
r @ asset_composer.5d2cd6d9613b85125812.js:1
p.setImmediate @ asset_composer.5d2cd6d9613b85125812.js:1
u._immediateFn @ asset_composer.5d2cd6d9613b85125812.js:1
c @ asset_composer.5d2cd6d9613b85125812.js:1
l @ asset_composer.5d2cd6d9613b85125812.js:1
f @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
h @ asset_composer.5d2cd6d9613b85125812.js:1
u @ asset_composer.5d2cd6d9613b85125812.js:1
postMessage (async)
r @ asset_composer.5d2cd6d9613b85125812.js:1
p.setImmediate @ asset_composer.5d2cd6d9613b85125812.js:1
u._immediateFn @ asset_composer.5d2cd6d9613b85125812.js:1
c @ asset_composer.5d2cd6d9613b85125812.js:1
l @ asset_composer.5d2cd6d9613b85125812.js:1
s @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
h @ asset_composer.5d2cd6d9613b85125812.js:1
u @ asset_composer.5d2cd6d9613b85125812.js:1
postMessage (async)
r @ asset_composer.5d2cd6d9613b85125812.js:1
p.setImmediate @ asset_composer.5d2cd6d9613b85125812.js:1
u._immediateFn @ asset_composer.5d2cd6d9613b85125812.js:1
c @ asset_composer.5d2cd6d9613b85125812.js:1
u.then @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
o @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
(anonymous) @ asset_composer.5d2cd6d9613b85125812.js:1
mtgm.js:92 [Violation] Added synchronous DOM mutation listener to a 'DOMNodeInserted' event. Consider using MutationObserver to make the page more responsive.
(anonymous) @ mtgm.js:92
pJuVy0o:33 GET https://test.profullstack.com/uploads/chovy/undefined 404
mtgm.js:92 [Violation] Added synchronous DOM mutation listener to a 'DOMNodeInserted' event. Consider using MutationObserver to make the page more responsive.
(anonymous) @ mtgm.js:92
VM9:1 GET https://checkout.stripe.com/api/color?image_url=https%3A%2F%2Ff001.backblazeb2.com%2Ffile%2Fpewtube%2Fpewtube%2FRCbutDM.jpg&key=&locale= 400
(anonymous) @ VM9:1
send @ inner-josqQy3MkFcBbpe84zFMQ.js:5
ajax @ inner-josqQy3MkFcBbpe84zFMQ.js:5
ravenAjaxWrapper @ inner-josqQy3MkFcBbpe84zFMQ.js:7
API.request @ inner-josqQy3MkFcBbpe84zFMQ.js:10
Color.fromImageURI @ inner-josqQy3MkFcBbpe84zFMQ.js:10
App.initColor @ inner-josqQy3MkFcBbpe84zFMQ.js:14
(anonymous) @ inner-josqQy3MkFcBbpe84zFMQ.js:14
App.preload @ inner-josqQy3MkFcBbpe84zFMQ.js:14
(anonymous) @ inner-josqQy3MkFcBbpe84zFMQ.js:14
RPC.processMessage @ inner-josqQy3MkFcBbpe84zFMQ.js:12
(anonymous) @ inner-josqQy3MkFcBbpe84zFMQ.js:12
RPC.message @ inner-josqQy3MkFcBbpe84zFMQ.js:12
(anonymous) @ inner-josqQy3MkFcBbpe84zFMQ.js:12
mtgm.js:92 [Violation] Added synchronous DOM mutation listener to a 'DOMNodeInserted' event. Consider using MutationObserver to make the page more responsive.
(anonymous) @ mtgm.js:92

The popular page scrolls horizontally on mobile

I don't have a screenshot for this, but when you are on popular you are able to swipe and move horizontally, and also zoom out. Seems like one of the divs is 'sticking out too far' but I couldn't figure it out when I looked at it.

Clean boot logs

Boot logs are pretty messy with deprecation warnings.

A great first step to cleaning the boot logs will be getting all those deprecation notices taken care

Fix media.pug page suggestion from user

Subscribe button should be "onRelease", not triggered onClick. I'm on mobile, it fires request when you scroll and happen to put your thumb where the button is

[Question] Video list links in navbar require admin role

Looking at the code that creates the main navigation bar, I see that some links that used to be available (Popular Uploads, Recent Uploads) require a user to have the role admin in order for those links to render. The actual pages are still accessible to normal users and guests though. Is that an oversight or why are those links not rendered for normal users?

There have been a few posts on Gab asking what happened to those old links since it is difficult to find new content without knowing about those pages.

Certain .mp4 formats are unplayable in Safari

Certain .mp4 formats are unworkable in Safari. To maximize browser compatibility some check should be added during upload that checks if the codec is compatible with Safari, and if not it should be converted.

Additional info here:

https://stackoverflow.com/questions/21120717/h-264-video-wont-play-on-ios
https://stackoverflow.com/questions/37967120/ffmpeg-convert-from-h-264-high-444-profile-to-h-264-main-profile
https://gist.github.com/Vestride/278e13915894821e1d6f

SAVE_AND_SERVE_FILES_DIRECTORY setting needs to be a relative path

While using the latest version, file errors kept appearing while attempting to upload a video, particularly for the mkdir calls. After inspection, it seems like the routine was trying to use an absolute path to a /uploads directory at the root file system as opposed to using nodetube/uploads. Removing the forward slash from the beginning was enough to make file uploading and saving work again.

SAVE_AND_SERVE_FILES_DIRECTORY='uploads'

finish winston configuration

the winston config needs some TLC and the whole thing needs documentation, I think it's either just barely finished and needs cleaning up or not quite finished yet

increase file size?

is there a file size limit I can increase? My vidoe wouldn't finish uploading.

Recaptcha Issue

I tried Recaptcha v2, invisible v3 and v3, but nodetube shows no Recaptcha logo and always says, "Captcha failed". Could you tell me how do I fix this issue?

TypeError: fs.copyFile is not a function when build on Heroku

Heroku build output:

   > node ./scripts/download.js
   
   Downloaded youtube-dl 2020.01.01
   
   > [email protected] postinstall /tmp/build_1a3dfca4bec3422176e286462dc2d57a
   > node ./postinstall.js
   
   /tmp/build_1a3dfca4bec3422176e286462dc2d57a/postinstall.js:4
   fs.copyFile('.env.settings.sample', '.env.settings', { flag: "wx" }, (err) => {
      ^
   
   TypeError: fs.copyFile is not a function
       at Object.<anonymous> (/tmp/build_1a3dfca4bec3422176e286462dc2d57a/postinstall.js:4:4)
       at Module._compile (module.js:573:30)
       at Object.Module._extensions..js (module.js:584:10)
       at Module.load (module.js:507:32)
       at tryModuleLoad (module.js:470:12)
       at Function.Module._load (module.js:462:3)
       at Function.Module.runMain (module.js:609:10)
       at startup (bootstrap_node.js:158:16)
       at bootstrap_node.js:578:3
   npm ERR! code ELIFECYCLE
   npm ERR! errno 1
   npm ERR! [email protected] postinstall: `node ./postinstall.js`
   npm ERR! Exit status 1
   npm ERR! 
   npm ERR! Failed at the [email protected] postinstall script.
   npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
   
   npm ERR! A complete log of this run can be found in:
   npm ERR!     /tmp/npmcache.mraWE/_logs/2020-01-07T06_30_38_574Z-debug.log
   -----> Build failed
   
   We're sorry this build is failing! You can troubleshoot common issues here:
   https://devcenter.heroku.com/articles/troubleshooting-node-deploys
   
   If you're stuck, please submit a ticket so we can help:
   https://help.heroku.com/
   
   Love,
   Heroku
   
  !     Push rejected, failed to compile Node.js app.
  !     Push failed

Is the uploads.uploadUrl field used in the production database?

I am working on optimizing some database queries in an attempt to get rid of COLLSCAN queries and I have a question about a possible stumbling block. Using the $or operator in a query such as in account.js (line 86) makes it so that a full index cannot be made that will match the query and sort the items. My local database with two upload documents shows that the uploadUrl field is not populated in either document. Does any upload document in the production database use that field? Is the uploads.uploadUrl field still relevant?

https://github.com/mayeaux/nodetube/blob/master/controllers/frontend/account.js#L86

Possibly cache legitViewAmount for media listing pages

One task that probably should be looked into at some point is speeding up processing to determine legitViewAmount. Populating checkedViews is a really expensive operation on my installation. Most queries are fast enough that they display 0 ms for the query time. Even with only 9 uploads with a total of 1,610 view documents, the query to obtain those documents for media listing pages usually takes around 14 - 16 ms. While browsing pages like /media/recent, the view count should probably come from a pre-computed value. The checkedViews array for an upload can be populated and examined when a user goes to a video page. The cached view value can be updated at that point.

https://github.com/mayeaux/nodetube/blob/master/controllers/frontend/mediaBrowsing.js#L83

Features:

  1. Unban user functionality
  2. Change username functionality
  3. Delete users files when banning user (or at least having it as an option)

HCaptcha / Recaptcha support

It would be super sweet if this had some ability to block bots. . What's cool is my site, hcaptcha.com allows you to make money while you block bots and is recaptcha compatible. Any interest for a patch?

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.