Can the cheapest $4 VM host a next app?

Поділитися
Вставка
  • Опубліковано 14 лис 2024

КОМЕНТАРІ •

  • @SeibertSwirl
    @SeibertSwirl Рік тому +31

    Good job babe!!!

  • @Kevin-fl4rn
    @Kevin-fl4rn Рік тому +2

    Very interesting to see tests like this done from someone who's mostly into frontend only. Would also be interested in a video like you mentioned of adding multiple droplets in a load balence

  • @UnknownIllusionist
    @UnknownIllusionist Рік тому

    This is a great practical demo that shows most side projects are going to be okay with simple architectures and low hardware costs

  • @amershboul9107
    @amershboul9107 Рік тому +2

    we need a video for deploying MERN Application with AWS and register a domain for that, with best practices for sure :)

  • @lilililliilil
    @lilililliilil Рік тому +8

    You always turn topics that I might have been curious about at least once into content. Today, you resolved my curiosity with your precious time! Thank you, Cody!

  • @aBradAbroad
    @aBradAbroad Рік тому

    I was literally just looking into this today. Great video, thanks for posting.

  • @ChrispyChris3
    @ChrispyChris3 Рік тому +2

    Funny you made this because I just recently saw you pop up and I also have been wondering about how much I could push through my cheap Linode VPS as opposed to going with all this serverless stuff people are constantly pushing. I want to learn serverless for sure, but I do love being able to host things myself, whether on VPS or home server! Great content, thanks!

  • @joshem32
    @joshem32 Рік тому +4

    Awesome video, you don’t get to see this kind of tests very often, I understand Next and Vercel go pretty much together, but it’s good to know there are other options that can actually do the job

  • @justine_chang39
    @justine_chang39 Рік тому

    bro this is exactly what I've been thinking about lately! Thanks so much for making this video!

  • @name_less227
    @name_less227 Рік тому

    Awesome video. Exactly what I've been researching lately now that I'm moving back to a Laravel monolith from nextjs.

  • @viktor-dy9tr
    @viktor-dy9tr Рік тому +1

    Thanks for the showcase.
    (note: Node is not single threaded)

    • @WebDevCody
      @WebDevCody  Рік тому +3

      In Node, the code we write is single threaded, but the io under the hood is multi threaded using a thread pool.

  • @richardjamesbunker
    @richardjamesbunker Рік тому

    Super informative! Thank you so much! That video really put into perspective the whole "but does it scale?" question because it's not just about the application stack and not just about the server but also the expectation around usage. For a small hobby app that has a small user base, it's clear that the $4 machine is almost - dare I say - overkill if that's even possible! Anyway, great video! And congrats on the 100k subs!

    • @michaelai8274
      @michaelai8274 Рік тому

      btw, since most companies are all into data analytics these day, I think every company would pretty much want to dedicate some work to analytics of their user engagement. If there are tools just like the one in this video that can help do these basic checks, I think by the time a company's user base and connections/requests is about to match the threshold the tools give, at that time, they could safely go with scaling.
      In my honestly opinion, I think it could be somewhat better on the pricing side, and btw, not trying to get kicked off a serverless platform is another thing. LoL

  • @mmzzzmeemee
    @mmzzzmeemee Рік тому +2

    Any chance you can do a breakdown of cloudflare pages with a next app?
    I've checked a few videos here on youtube, but haven't found that much.

  • @anuragk6722
    @anuragk6722 Рік тому

    This topic has crossed my mind multiple times but i never went ahead & did it.. thanks

  • @ephotopros
    @ephotopros Рік тому

    great video, any idea what the cpu utilization was while doing this? also on AWS the servers usually(?) have a boosted capacity for a minimum amount of time but once you use that up if you continue to have that much traffic it could hurt - but that was a lot of traffic for most of us. My servers never use up the credits for the boosted capacity but it is nice to have it always available.

  • @proevilz
    @proevilz Рік тому

    this was a really good vid, thanks!

  • @jaany
    @jaany Рік тому

    For anyone curious, typically on DO the Premium AMD droplets perform better than Intel for some services. I'd recommend doing some research what may fit yours best if you come into a situation where you're scaling up.

  • @SeanCassiere
    @SeanCassiere Рік тому +2

    If feasible, could you spin up a db in the same box and see how it buckles under the load of having to form a db connection and a read on page load?

  • @chinochao
    @chinochao Рік тому

    You are doing what a developer might think of doing when they host their own stuff. But as a system engineer or administrator you are missing a lot of things, like looking at your server resources and see where your bottlenecks are, cpu, memory, IO and see where you can improve. Example of adding caching for static content like Nginx, etc.
    A lot of performance can be tweak when you see your server resources and also see where in your code you can also improve to help reduce those resources used.

  • @yousafwazir3167
    @yousafwazir3167 Рік тому +1

    A video do you trying redis ?

  • @Quiqsave
    @Quiqsave Рік тому

    super informative video! really enjoyed it

  • @sandervspl
    @sandervspl Рік тому

    Careful using pm2 with Nextjs. If you have multiple instances and you use revalidate on GSP, only 1 instance will be revalidated at a time instead of all of them at the same time. The docs say you can use FS instead of memory for revalidated pages, but it is difficult to test if this actually fixes the issue. We’ve had angry clients because of this 😅

    • @ko-Daegu
      @ko-Daegu Рік тому

      So what do u propose as a solution ?

  • @ashfordyt
    @ashfordyt Рік тому

    I have a weird request but I hope if you could take it into consideration !
    As a development student ( and I'm not that bad at it ) I've been in love with coding since a very young age and I'm a quick learner and all that.
    But lately I've been having some issues with motivation, I find myself not touching code for weeks, leaving personal learning projects hanging, and when I decide to pick up where I left off, I find my brain wiped clean which is even more frustrating and pushes me even further away.
    I want your opinion on how can I deal with such issue, how do I keep myself motivated and stick to a pattern/schedule... How do I stop these long no coding breaks ( for literally no reason other than just not doing it ).
    I see you love what you do and I love that about you and I wish you could make a video for us, learners and students telling us your advice to stay motivated and go even further down the road ! It would really help coming from you as you're my favorite coding youtuber of all time !

    • @WebDevCody
      @WebDevCody  Рік тому +2

      I’d say allocate 30 min a day to work on your projects. You just need discipline, not motivation. Treat it like a job

    • @michaelai8274
      @michaelai8274 Рік тому +1

      Just as Cody said, some time allocated everyday would help, like 30mins to 1hour. Also, make sure you are not messing up your night, like staying awake. It affects the brain, this from personal experience. Anytime I get a good sleep, I remember usually what I was doing the day before.

  • @rahultech77
    @rahultech77 Рік тому

    What are your thoughts of perf testing between JMeter and k6?

  • @amasoharnold4762
    @amasoharnold4762 Рік тому +1

    I’ve been recently looking into this too glad you did a video for it
    I guess if there was like a database inside that same vps it might hurt the performance
    Also if it’s just serving HTML and you using node would something like golang or rust be able to utilize resources better and be faster

    • @michaelai8274
      @michaelai8274 Рік тому

      I think this is a great idea. I just learnt from this video as well that node is single threaded, no wonder enterprise and big tech have stood with java for the longest times.
      The ones switching or porting over a bit are doing so to Go and Rust as well, especially Go.

    • @amasoharnold4762
      @amasoharnold4762 Рік тому

      @@michaelai8274 I'm not particularly certain about the actual version, but I'm pretty sure since node 16 node can do multi-threaded tasks
      They didn't use to have the feature, so it's not really well known and it's a bit different from how other languages that have first-class support for multi treading but it definitely has support for working with multiple threads

  • @REAZNx
    @REAZNx Рік тому

    Digital Ocean is ludicrously expensive, you can get a same spec OVH server for more than half the price.

  • @fer.guitar
    @fer.guitar Рік тому

    Great and informative video!

  • @andresgutgon
    @andresgutgon Рік тому

    Super helpful!

  • @antonpetrov145
    @antonpetrov145 Рік тому

    Can you use kubernetes and docker on this droplet to scale horizontally with pods?

    • @WebDevCody
      @WebDevCody  Рік тому

      I think DigitalOcean provides a k8s option, so yes. They also have an app runner which you can specify how many machines

    • @antonpetrov145
      @antonpetrov145 Рік тому

      @@WebDevCody Nice, thanks

  • @thalespica
    @thalespica Рік тому

    Awesome video. Interesting ❤

  • @senpos
    @senpos Рік тому

    Dang, DO is not cheap. Hetzner provides a VM with 2GB RAM for similar price?

  • @DaviAreias
    @DaviAreias Рік тому

    I host my apps in a 6$ droplet and also use it as a VPN sometimes

  • @st-jn2gk
    @st-jn2gk Рік тому

    This was really amazing man. Thank you for what you do. o7

  • @canadianbeast8671
    @canadianbeast8671 Рік тому

    Does the cheapest plan $4/MO provides a MYSQL Database?

  • @OmgImAlexis
    @OmgImAlexis Рік тому

    35/s seems really really low for the small box. Sounds like something isn’t setup correctly.

    • @WebDevCody
      @WebDevCody  Рік тому

      Yeah I think the jmeter actually means the test plan request. So each test plan request does like 12-15 total request each run, so 35 * 15 = 525 request / second?

    • @ChrispyChris3
      @ChrispyChris3 Рік тому

      @@WebDevCody This is definitely an interesting note, I'm curious now how the JMeter puts together that number.

  • @louispoirot-hattermann4178
    @louispoirot-hattermann4178 Рік тому

    99% of SaaS application need AWS/Versel lowest plan, with CDN and caching system to not blow database. People that use Redis/Memcache seems overkill for me, File Cache is way enough. The only avantage is that you can share your cache with others instancies (but once again 99% of saas will need only one instance and the lowest one) and is it real performance issue to warm-up your file cache for the new instance.

  • @andreim6342
    @andreim6342 Рік тому +1

    nice! comm for the algo 👌

  • @rajusharma823
    @rajusharma823 Рік тому

    Oh a thumbnail 😄

  • @3IMAD69
    @3IMAD69 Рік тому

    how to put my app behind a cdn ?

    • @WebDevCody
      @WebDevCody  Рік тому

      DigitalOcean has an app deploy feature that will deploy your app from GitHub and put behind a cdn

  • @christiantechlead5901
    @christiantechlead5901 Рік тому

    Node is not single threaded. It has a v8 engine

  • @m3mphi5r4r7
    @m3mphi5r4r7 Рік тому

    Do a test on nodejs api server.

  • @changNoi1337
    @changNoi1337 Рік тому

    super cool!

  • @SalvaToroTorus
    @SalvaToroTorus 8 місяців тому

    interesting stuff

  • @insensibility
    @insensibility Рік тому +2

    Trying out thumbnails, huh?

    • @WebDevCody
      @WebDevCody  Рік тому +3

      Yeah just seeing how it works

  • @mzfitness5533
    @mzfitness5533 Рік тому

    happy to hear my cody onlyfans side project will do just fine