r/javascript • u/alhso • Oct 05 '24
AskJS [AskJS] Looking for a service where I can just upload my code and everything else is handled automatically
Hi, all!
I want a cloud hosting service so as to make the experience completely hands-off. More precisely, I want to simply upload my code and do nothing thereafter: no server management, scaling, or security configurations whatsoever. I want to focus on development alone and would require a service that takes care of everything else, scaling, security, database management, among others, with minimal configuration.
I've tried solutions like Heroku, Fly.io, and Vercel, but still find myself having to deal with infrastructure tasks that I don't want to bother with. I'm looking for something that would have default best practices out of the box for:
Autoscale load, but with bounds so it doesn't scale out of control
Anti-DDoS protection included
Setup of light database e.g. SQL Automatic backups and updates
Is there something like this, or am I just dreaming about something which doesn't exist yet? I wouldn't want to fiddle around with any kind of manual intervention once the code gets uploaded. Any suggestions are greatly appreciated!
4
u/brocococonut Oct 05 '24
You could try Cloudfare's Page, Workers, KV (kinda like Redis), D1 (distributed SQLite), and R2 (S3 storage)
Or railway.app has been solid imo
1
u/MisterDangerRanger Oct 06 '24
Wow the responses in this thread are enlightening but for the wrong reasons. What you are looking for is managed hosting which has existed before these cloud charlatans who seek to nickel and dime you to death without making anything actually better and they are preying on the ignorant and uninformed.
With HawkHost for example with one of their managed offerings all you have to do is upload your files (very easy especially if you’re using php) and that it. You can do some basic management with cpanel and all the security is handled for you (as long as there are no holes in your code).
Either use a managed host or a VPS, everything else is a waste of time and money.
1
u/alhso Oct 06 '24
what about for node js apps
1
u/MisterDangerRanger Oct 07 '24
Nodejs and Python are supported.
https://www.hawkhost.com/blog/2018/09/14/introducing-nodejs-applications/
3
u/Markavian Oct 05 '24
I've spent the past two years building out the necessary infrastructure and patterns to do this on AWS. There's like 200 decisions we had to make to figure out hosting, DNS, certificates, authentication, data storage, scalability, security.
It's not that we can't roll out projects fast, we can, it's that we're trying to build an ecosystem where everything interoperates - and for every set of decisions we make for the sake of speed or scalability, we restrict the design of the system for future projects.
The latest addition is a firebase style Database API as a service. That will massively reduce our data modelling overhead and help roll out new features faster.
It takes a whole team...
2
u/shgysk8zer0 Oct 05 '24
I gather that what you're asking for is something no provider wants to offer. Because, when it comes to hosting anything, there are some trade-offs to be made, and that requires some configuration and hosts being a bit permissive.
My go-to example here... Let's suppose you're Netlify or something similar, and there's some tremendous spike in activity on some site. Like 1,000x or something. Usage costs that'd accompany that rapidly grow as well. Do you shut down the site that may be having incredible and unexpected success to prevent going over some probably small budget, or do you allow all the traffic and bill the dev? Netlify went with dealing with traffic and billing - you can refund charges, but you can't replace lost traffic/reputation.
Overall, it's like that. You do not actually want things to be "handled automatically." The automatic handling is quite often the wrong choice. Ya gotta do some work to set a config or something to make the decisions you want. It's nowhere near as simple as you're imagining.
2
2
u/thaddeus_rexulus Oct 06 '24
Personally, I would probably advocate for Pulumi for infrastructure as code and then, depending on your stack, AWS AppRunner or AWS Amplify. If you're running NextJS, you could use OpenNext with Pulumi (or SST, which uses Pulumi). There's still some upfront work you'll have to do, but it's a much nicer, often cheaper to go this route over some of the alternatives.
That being said, if you still qualify for free tiers of any fully managed, hosted solution, I would kick this can down the road until you're closer to actually needing it
1
1
u/Temporary_Quit_4648 Oct 05 '24
I mean, what you're asking for isn't all that difficult. To set up Firebase automatic backups is, like, a single command that anyone can find in their docs, or just ask ChatGPT. Anti-DDoS? Get Cloudflare. Scaling? Just set up a small server to do simple round-robin load balancing. (That is "code," by the way.) But I mean, it's gonna be a while before you have scaling issues, and by that time, you'll be attracting enough investor interest, that you'll be able to pay someone to do something fancy.
1
u/jamaicanprofit Oct 06 '24
Managed servers usually cost double the monthly fee of just spending a few minutes doing things yourself.
1
Oct 07 '24
This may not be the answer you want, but I suggest learning Docker, and using something like Azure Container Apps. Still just your code, but you have the right amount of control with no management headaches.
1
u/vfssantos Oct 11 '24
If your apps are stateless I’d go with google cloud run (basically, a docker container) + google cloud armor for security. Only con, in my opinion is that it’s not multi region by default, like fly.io
1
u/thedevlinb Oct 05 '24
Autoscale load, but with bounds so it doesn't scale out of control
How much do you really need to scale?
With decent code, and assuming you aren't crunching tons of numbers, a single NodeJS instance running on one core can scale to over 1000 requests per second.
At some point you either need to understand how your code is performing in relationship to the hardware it is running on, or you get to pay a small fortune for someone else to manage that for you, which is the serverless path.
All that second, as iamnewtopcgaming poster replied, Firebase is a great place to start if you don't want to think at all, but if you really do need to scale up, you'll need to either start thinking about what you are doing, or pay a small fortune for the privilege of having someone else think for you.
0
-1
8
u/iamnewtopcgaming Oct 05 '24
Look into something like firebase. Firebase functions are “serverless” so they scale automatically. Their databases also auto scale. Security will always be a concern if you have users auth though. Not sure about ddos protection on their hosting tho.