Live data from Hacker News

Ask HN: What is the cheapest, easiest way to host a cronjob in 2022?

news.ycombinator.com

301–310 of 336 posts

Re: Ask HN: What is the cheapest, easiest way to host a cronjob in 2022?

#302
post #283

Earlier quoted context omitted.

I don't see how it's satirical. If you need a job to run, you need to handle the case of transient node failures. K8S helps alleviate this issue by allowing the job to be launched on any of a choice of nodes. Sure, cron is fine if you're just looking to rotate logs on the local machine, but if you want to reset your nuclear watchdog timer, you may want something more reliable :)

I'm sensing a need for a blockchain here.

These replies made my day. Thanks guys.

Re: Ask HN: What is the cheapest, easiest way to host a cronjob in 2022?

#303
post #260

Earlier quoted context omitted.

Not just a multi-cloud, but also managed kafka and a managed db across a multi-region deployment. Regions can fail, your job needs persistence and you need to maintain the state of the message in the db.. oh!! have you also thought about the right queue semantics? Do you want your job to trigger exactly one, at least one or at most once? What happens if the previous job is still running when it is time to trigger it…

It'd be literally impossible to deploy any of this lightweight, cloud-native architecture without at least 14 Terraform modules as well, maybe more (just to be safe).

I cannot unthink of

It's the future (2015) https://circleci.com/blog/its-the-future/

Re: Ask HN: What is the cheapest, easiest way to host a cronjob in 2022?

#304
Probably not the cheapest, but I created beew.io to be the easyest.

https://beew.io/

You can create cron jobs over HTTP, both recurring and one-time:

Node SDK: https://www.npmjs.com/package/beew API Reference: https://beew.io/api

You can also create directly trough the UI.

Let me know if you need any help

Re: Ask HN: What is the cheapest, easiest way to host a cronjob in 2022?

#306
hello,

you want to watch a web-page - apparently they have no RSS-feed in 2022... that got out of fashion a long time ago:

cheap: on one of your existing systems [workstation|raspberry|laptop|home-router|server|vm|cloudinstance]

easy: idk. in a short shell-script do something like:

curl -o /tmp/somefile-

diff /tmp/somefile- /tmp/otherfile-

or calculate a hashvalue of the page & compare ...

or go for the last-modified, e-tag or content-length in the http-header

curl -I

put this file into your systems crontab.

just my 0.02€

Re: Ask HN: What is the cheapest, easiest way to host a cronjob in 2022?

#307
Check out scheduled jobs feature of Superblocks (https://www.superblocks.com/product/scheduled-jobs). We've got a robust free tier (https://www.superblocks.com/pricing) and support Python, NodeJS, REST, GraphQL and a heck ton of DB integrations.

Re: Ask HN: What is the cheapest, easiest way to host a cronjob in 2022?

#308
post #108

Most folks here are focusing on the scheduling part, but change detection means you need some way to persist state (or have a long running process that keeps state in memory). While you could do FaaS (e.g. AWS Lambda) + another service for state (e.g. S3/RDS/EFS), that seems like overkill. Even today I would still do it the old way: store state in a filesystem (maybe SQLite if you have more complex needs), and config…

Put the 10 lines in a Lambda and invoke it from a schedule in EventBridge. Done. If you follow the default settings you'll get Cloudwatch logging as well.

Re: Ask HN: What is the cheapest, easiest way to host a cronjob in 2022?

#309
post #256

Can someone please enlighten me on what is the purpose of using an external Cron runner here? If I need to run the same job(s) for a long time, wouldn't it be simpler and cheaper to run a basic $5 VM on something like Linode?

The motivation is some of the "serverless" offerings may be near free if you are only firing this say once a day and the script is very fast to run.

Yes maybe, however the guy said he wants to run once per hour. On top of that he will certainly need some form of persistence in order to do diff. Not to mention that some of the serverless solution suggested in other comments have short execution time limit, which if he happen to scan a large site, that would be insufficient. Yes maybe not everyone is willing to pay $5 per month, but in this case I think it strike a reasonable point between cost, speed, reliability and ease of use.

Re: Ask HN: What is the cheapest, easiest way to host a cronjob in 2022?

#310

You should check out Modal! Does much more than just cronjobs, but super easy and cheap: https://modal.com/docs/guide/cron . They have an example with a simple web scraper as well: https://modal.com/docs/guide/web-scraper From their pricing example: > You schedule a job to run once an hour for 15 seconds. This job uses 50% of one CPU core and 256 MiB of memory. This job will cost $0.016/day for the CPU, and $0.001/da…

Wow
Post reply on HN