You are browsing as a guest. Sign up (or log in) to start making projects!

Rune - server-less function runner

  • 11 Devlogs
  • 43 Total hours

tried to build a serverless function runner with go (first learning this language) And adapt js by quickjs, python by starlark (Python-like)

Ship #1

I’m making an app that works like Cloudflare Workers, but with fewer features.

My goal is to enable it to handle unlimited requests seamlessly. While it still has a long way to go compared to Cloudflare Workers—especially in areas like storage, AI utilities, npm package support, and project-based file uploads—I think it’s already good enough for basic use cases.

If you’d like to test it out:

Username: hackclub
Password: hackclub


If you want to test the domain utilities, you can check it out here: https://hello-world-rune.pazik.win/
(Note: Since I’m hosting the web server using Cloudflare Tunnels, I can’t use hello-world.rune.pazik.win directly due to missing SSL certificates. To work around this, I rewrite its Host header).

One thing to keep in mind: The service has a rate limiter enabled, so you might get temporarily blocked while testing.

  • 11 devlogs
  • 43h
  • 16.16x multiplier
  • 700 Stardust
Try project → See source code →
Open comments for this post

2h 31m 5s logged

  1. make function execute by sub-domain (see image below)
  2. add kv store endpoint (and also dashboard)
  3. make you able to make function private (still can test)
  4. warp function kv_set/ delete/get into a object
    (kv.set / kv.delete / kv.get)
0
0
16
Open comments for this post

7h 48m 16s logged

  1. Finished the frontend (with help from AI)
  2. Bug fixing (a lot of bugs… one of them was a deadlock during environment injection)
  3. Passed requests to functions (it can now process requests)
  4. Added more information to execution details (debug info)

Ahhh…
The frontend is almost finished,with some examples and API documentation (all in the same docs).
Built using Nuxt UI and Vue.
The next devlog should be the last one before the first release.
I’ll make it able to detect the hostname to handle function calls (similar to Cloudflare Workers).

Screenshot is part of the website

1
0
5
Open comments for this post

6h 59m 4s logged

  1. Add a rate limiter to API endpoints (the rate limit for each function can be modified via API).
  2. Add key-value storage (accessible only in scripts).
  3. Add environment variable storage (can be updated via API).
  4. Change user-related APIs to admin-only access.

The basic functionality I think is needed has been completed.
Next step: build the frontend (admin panel and documentation).

0
0
6
Open comments for this post

6h 40m 52s logged

  1. Write a simple router using the built-in net/http.
  2. Design a basic database schema to store binaries and function information.
  3. Create a database wrapper. (which use Transaction as main exec method)
  4. Support two languages that can compile and execute from binaries.
  5. Ensure both languages can generate responses (JavaScript returns an object, Starlark returns a dict).
  6. Build a simple HTTP server to test functions (compile / execute / save to DB).

TODO:

  1. Add support for Starlark.
  2. Implement authentication.
  3. Create a frontend / admin panel.

It might take some time to work on next step.
Not only because it have lots things to do, also due to I am trying to create something by 3D Printing.
Spending too much time on it…
If I can share those model. It will be nice.

0
0
5
Open comments for this post

2h 13m 24s logged

Just add more function to fetch and response.
and force js function return obj as response source.

and maybe I will give up on settimeout (though I didn’t try.) maybe after finish main function.
also I will make js function first.
still didn’t know how to let starlark have async ability.
Seems like js code didn’t work properly…
fix it nextday!

0
0
3
Open comments for this post

2h 55m 19s logged

  1. change quickjs lib from modernc.org/quickjs to github.com/fastschema/qjs for better control
  2. add async sleep and simple fetch function for js (work as builtin function)
  3. add a simple http related file to do any http related things

Next might be add fetch in starlark
and try to make it have async
and maybe make a settimeout?
also needed to extend fetch function (currently only have basic function)

0
0
1

Delete project?

Are you sure you want to permanently delete this project? This action cannot be undone.

All devlogs, followers, and associated data will be removed.

Followers

Loading…