Better HN
topnewbestaskshowjobs
Log inSign up

ilbert

32 karma · joined Jun 21, 2020 (6y ago) · 45 submissions

Always getting hands dirty on many projects: https://github.com/ilbertt
Submissions

comment 1mo ago · link · parent

Crazy how versatile SQLite is!

comment 2mo ago · link · parent

Nice suggestion! I've been working on https://github.com/ilbertt/nibrunner now to give people an easy and fast way to turn theri VPS into a microVM host

comment 2mo ago · link · parent

I build a lot of small apps, and often times most of the effort goes into the infra rather than the app. I typically only need a machine and a disk where to run the compiled binary, but I can't find it on any of the existing cloud solutions. The "batteries included" platforms give you Postgres and object storage but nowhere to run your own binary. Vercel and friends will run your code as a function with an ephemeral filesystem, so an SQLite file is gone the moment the request ends unless you configure additional services. Using a VM means ssh, a firewall to open, TLS to renew, and an OS to keep updated. They're all either difficult to configure and maintain or an overkill, or both.

It doesn't happen only when I build my apps, but also every time I find a good open-source project that ships as a single binary. Hosting it means one of the above again, or wrapping it in a container image when it was already deployable as a single file. Self-hostable single-binary projects are great until you have to host them.

So I built nibrun. You upload a binary executable, and you get an isolated Firecracker microVM (1 vCPU, 256 MiB) and an 8 GiB persisted volume. The volume is all yours to use, as if it was your local machine: write your SQLite file, JSONs, assets uploads. And it's instantly available via HTTPS. No extra config file or Docker image needed. It sleeps after 5 minutes idle and wakes up on incoming requests in ~120 ms.

For example, you can deploy PocketBase (single-binary Supabase clone) in one click: https://nibrun.com/deploy/pocketbase

And when you want to leave, the export button gives you back the binary and everything in the volume, so leaving only costs you the download of a zip file.

All open source, so you can even run the whole platform on your own AWS account: https://github.com/ilbertt/nibrun

4.

Ask HN: Framework to Manage Firecracker?

2 points · by ilbert · 2mo ago · 2 comments

5.

Small apps don't need to scale. They need a VM and a disk(nibrun.com ↗)

7 points · by ilbert · 2mo ago · discuss

comment 4mo ago · link · parent

Actually, after reading more carefully, it seems that custom notifications won't be supported anymore in favor of the `subscriptions/listen` RPC endpoint. Maybe the upcoming extensions will make it possible?

comment 4mo ago · link · parent

Thanks for sharing this SEP. Yeah some system notifications will go away, but servers will still be able to send custom notifications. Those can be turned into push notification on the device of the user or even actions that the user's device can do programmatically.

8.

Ask HN: Is anyone using MCP notifications?

3 points · by ilbert · 4mo ago · 4 comments

comment 4mo ago · link · parent

Really cool, same concept as Pocketbase.

Starred!

10.

Ask HN: Why aren't we collaborating on the prompts we give to our AI agents?

1 points · by ilbert · 4mo ago · discuss

comment 4mo ago · link · parent

Software like this make me questioning a lot the defensibility of products such as Wispr Flow.

A friend of mine created something similar with just a few prompts, allo working locally, and he's stopped using Wispr Flow

comment 5mo ago · link · parent

That's actually the library that inspired me the most for building bun-sqlgen

comment 5mo ago · link · parent

sql<type>`query` is the reason why I started bun-sqlgen, to not have to write types manually

comment 5mo ago · link · parent

I've updated the READMEs by the way

comment 5mo ago · link · parent

Really cool! I see you don't discover the SQL in the code right?

comment 5mo ago · link · parent

Kysely is really cool, but I don't like that you are not writing SQL directly

comment 5mo ago · link · parent

No real reason, I was working with Bun's SQL module for a project and felt the need for such codegen. I'm thinking of generalizing it to Node.js

comment 5mo ago · link · parent

Yeah, I'm still iterating on the docs

comment 5mo ago · link · parent

I actually took a lot of inspiration from sqlx, which is really nice. The main differences are:

- in JS/TS you don't have compile-time scripts that you can run like with Rust's macros, so you need to run a codegen command before running the type checks (disadvantage)

- I had to create a TS parser that goes and finds the tagged template functions with the sql statements, while sqlx has them "for free" because sql statements are the input to the macro itself (disadvantage)

- I use an in-memory Postgres (PGLite) to describe the queries, instead of requiring a running pg instance (advantage)

- I don't cache the statements and codegen for now like sqlx does, something that can be added later

I think they are similar in that they both substitute the dynamic params with no-ops like $1, $2, etc. before handing the sql statement to the pg's DESCRIBE function

comment 5mo ago · link · parent

I was targeting Bun because I really like its built-in SQL module. I can tweak the TS parser to look for e.g. postgres.js tagged template functions and make it work for that as well. I don't really see any blockers
12