Live data from Hacker News

Serverless Horrors

serverlesshorrors.com

51–60 of 503 posts

Re: Serverless Horrors

#51
post #25
post #14

Earlier quoted context omitted.

No. Your buckets should be private, with a security rule that they can only be accessed by your CDN provider, precisely to force the CDN to be used.

Why isn't that the default? I'm glad I use a Hetzner VPS. I pay about EUR 5 monthly, and never have to worry about unexpected bills.

Don't they charge for every TB exceeding the included limit? (website says "For each additional TB, we charge € 1.19 in the EU and US, and € 8.81 in Singapore.")

Re: Serverless Horrors

#52
I've had this twice. Once with oracle, once with azure. They both charged me $2000-$5000 for simply opening and closing a database instance (used only for a single day to test a friend's open source project)

To be fair, support was excellent both times and they waived the bills after I explained the situation.

Re: Serverless Horrors

#53
post #46
post #25

Earlier quoted context omitted.

Why isn't that the default? I'm glad I use a Hetzner VPS. I pay about EUR 5 monthly, and never have to worry about unexpected bills.

Because not all uses for buckets fit that. Buckets are used for backups, user uploads, and lots of things other than distributing files publicly.

I would say its probably not a good idea to make a bucket directly publicly accessible, but people do not do that.

A lot of the point of serverless is convenience and less admin and things like adding a layer in front of the bucket that could authenticate, rate limit etc. is not convenient and requires more admin.

Re: Serverless Horrors

#54
post #47

When I was learning to program through a bootcamp I spun up an elastic beanstalk instance that was free but required a credit card to prove your identity. No problem that makes sense - it's an easy way to prove authentication as a bot can't spam a credit card (or else it would be financial fraud and most likely a felony). Amazon then charged me one hundred thousand dollars as the server was hit by bot spam. I had the…

That’s why I prefer prepaid cards or those I can easily freeze to prevent any booking.

If your card is declined and they don't feel like forgiving the bill, won't they just send debt collectors after you instead?

Re: Serverless Horrors

#55
The real serverless horror isn't the occasional mistake that leads to a single huge bill, it's the monthly creep. It's so easy to spin up a resource and leave it running. It's just a few bucks, right?

I worked for a small venture-funded "cloud-first" company and our AWS bill was a sawtooth waveform. Every month the bill would creep up by a thousand bucks or so, until it hit $20k at which point the COO would notice and then it would be all hands on deck until we got the bill under $10k or so. Rinse and repeat but over a few years I'm sure we wasted more money than many of the examples on serverlesshorrors.com, just a few $k at a time instead of one lump.

Re: Serverless Horrors

#56
post #28

Are there any protections these days at the cloud provider level? Like setting a maximum budget for a certain service (EC2, Aurora?) because downtime is preferable to this?

Not _really_. AWS has a budget tool, but it doesn’t natively support shutting down services. Of course, you can ingest the alerts it sends any way you want, including feeding them into pipelines that disable services. There’s plenty of blueprints you can copy for this. More seriously - and this is a legitimate technical limitation - of course AWS doesn’t check each S3 request or Lambda invocation against your budget, instead, it consolidates periodically via background reporting processes. That means there’s some lag, and you are responsible for any costs incurred that go over budget between such reporting runs.

Re: Serverless Horrors

#57
post #28

Are there any protections these days at the cloud provider level? Like setting a maximum budget for a certain service (EC2, Aurora?) because downtime is preferable to this?

Just set alerts that are not really timely and homeroll your own kill scripts its easy. It doesn't really work but its not really any harder than just fucking self hosting.

Re: Serverless Horrors

#59
post #47

When I was learning to program through a bootcamp I spun up an elastic beanstalk instance that was free but required a credit card to prove your identity. No problem that makes sense - it's an easy way to prove authentication as a bot can't spam a credit card (or else it would be financial fraud and most likely a felony). Amazon then charged me one hundred thousand dollars as the server was hit by bot spam. I had the…

That’s why I prefer prepaid cards or those I can easily freeze to prevent any booking.

Freezing a card doesn’t mean the debt is erased. They can still take you to collections.

Re: Serverless Horrors

#60

Earlier quoted context omitted.

This story is giving "I leave OWASP top 10 vulns in my code because hacker mindset". It's not that hard to configure access controls, they're probably cutting corners on other areas as well. I wouldn't trust anything this person is responsible for.

It's about rate limiting, not access controls. Without implementing limits your spend can go above what your budget is. Without cloud you hit natural rate limits of the hardware you are using to host.

That might be the more general solution but in this context it is absolutely also an access control issue.
Post reply on HN