Skip to content

Start converting Kubernetes to Rust#138147

Closed
rikatz wants to merge 1 commit intokubernetes:masterfrom
rikatz:rust-apiserver
Closed

Start converting Kubernetes to Rust#138147
rikatz wants to merge 1 commit intokubernetes:masterfrom
rikatz:rust-apiserver

Conversation

@rikatz
Copy link
Copy Markdown
Member

@rikatz rikatz commented Apr 1, 2026

What type of PR is this?

/kind cleanup

What this PR does / why we need it:

We all know Rust is better for everything. Rust is the best language for every safe program, and given Kubernetes importance around, we must start converting it to Rust!

This is also the initial step to integrating Kubernetes into the Linux Kernel

Which issue(s) this PR is related to:

No KEP is needed, just yolo it

Special notes for your reviewer:

Look at your calendar

Does this PR introduce a user-facing change?

NONE

Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:


@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Apr 1, 2026
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

This issue is currently awaiting triage.

If a SIG or subproject determines this is a relevant issue, they will accept it by applying the triage/accepted label and provide further guidance.

The triage/accepted label can be added by org members by writing /triage accepted in a comment.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added the needs-priority Indicates a PR lacks a `priority/foo` label and requires one. label Apr 1, 2026
@k8s-ci-robot k8s-ci-robot requested review from liggitt and soltysh April 1, 2026 10:21
@rikatz rikatz marked this pull request as draft April 1, 2026 10:22
@k8s-ci-robot k8s-ci-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Apr 1, 2026
@rikatz
Copy link
Copy Markdown
Member Author

rikatz commented Apr 1, 2026

/hold
/label needs-ok-to-test

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Apr 1, 2026
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

@rikatz: The label(s) /label needs-ok-to-test cannot be applied. These labels are supported: api-review, tide/merge-method-merge, tide/merge-method-rebase, tide/merge-method-squash, team/katacoda, refactor, ci-short, ci-extended, ci-full, official-cve-feed. Is this label configured under labels -> additional_labels or labels -> restricted_labels in plugin.yaml?

Details

In response to this:

/hold
/label needs-ok-to-test

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added area/kubelet sig/node Categorizes an issue or PR as relevant to SIG Node. labels Apr 1, 2026
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. label Apr 1, 2026
@dims
Copy link
Copy Markdown
Member

dims commented Apr 1, 2026

giphy

@dprotaso
Copy link
Copy Markdown
Contributor

dprotaso commented Apr 1, 2026

We should start with etcd first

@rikatz
Copy link
Copy Markdown
Member Author

rikatz commented Apr 1, 2026

I would rather migrate etcd to Perl and make it a k/v regex database

@Verolop
Copy link
Copy Markdown

Verolop commented Apr 1, 2026

make sure to make cherry picks for the previous branches too. I'll LGTM and approve immediately.

@xmulligan
Copy link
Copy Markdown

Which AI tool are you using to make this conversion? Looks like a weekend project to rewrite either way

@rikatz
Copy link
Copy Markdown
Member Author

rikatz commented Apr 1, 2026

Exactly, no AI is needed, just me, a bucket of coffee and some free time during my weekend.

@Skyb0rg007
Copy link
Copy Markdown

I can’t wait to write Kubernetes TOML

@dgabrysch
Copy link
Copy Markdown

Wth is this 😂

@dystopiandev
Copy link
Copy Markdown

Start by introducing the most important module: age verification for each kubectl apply.

@rohitg00
Copy link
Copy Markdown

rohitg00 commented Apr 1, 2026

/kubernetes merge it to main 😂

@afro-coder
Copy link
Copy Markdown

Wasn't the goal to write it to assembly for performance gains* claude max pro will do it.

@k8s-ci-robot
Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: dkanas, rikatz, shlomitubul
Once this PR has been reviewed and has the lgtm label, please assign liggitt for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@shivaylamba
Copy link
Copy Markdown

/kubernetes merge it to main 😂

I am sure @rohitg00 will be the one to do the actual migration

@bexxmodd
Copy link
Copy Markdown

bexxmodd commented Apr 1, 2026

🦀

@DhairyaMajmudar
Copy link
Copy Markdown

I was shocked for a while, then realised it's 1st of April today XD

@bowei
Copy link
Copy Markdown
Member

bowei commented Apr 1, 2026

https://en.wikipedia.org/wiki/Carcinisation

@ivanbaldo
Copy link
Copy Markdown

Just ask the AI to rewrite everything into plain C, they are so smart nowadays that they will write perfect code without bugs or security issues, GUARANTEED!!! :-D

@ivanbaldo
Copy link
Copy Markdown

And call it Kubernetes 2.0.0, it's about time!

@DamianSawicki
Copy link
Copy Markdown
Contributor

+1 from me, great job @rikatz! 🙏🙏🙏

After a successful launch after the weekend, let's prioritize rewriting kubernetes-sigs. I volunteer to help with Gateway API.

@rikatz
Copy link
Copy Markdown
Member Author

rikatz commented Apr 1, 2026

I would start with something less important than Gateway API on kubernetes-sigs, like controller-runtime. I am sure @sbueringer would approve it

@DamianSawicki
Copy link
Copy Markdown
Contributor

Perhaps it's also the right time to replace KubeDNS with generative AI DNS, which you've been planning for some time, @Michcioperz?

@mtors25
Copy link
Copy Markdown

mtors25 commented Apr 1, 2026

Guys, if you're serious about tacking this project, I will be happy to participate. However, I need to clarify a few points first.

What underlying OS are you considering? Is it an immutable one? We will need a better alternative to etcd. Are we prepared to develop a superior option that includes multisite, multicluster capabilities, an improved consensus protocol, robust backup and recovery systems. The project must be ready to support algorithms that enable post-quantum cryptography? Will it support HTTP/3 as the default? Are you planning to allow current operators to run on top of the platform, or are you aiming to create a new ecosystem? Will eBPF be the default for networking and observability? How many architects will you bring onto the team? Who will be tasked with creating extensive documentation? Are you planning to incorporate LLMs into this project, and what type of license are you considering? Will you create a completely new fork? How do you plan to fund the project and generate revenue? Thank you very much!

@thereisnotime

This comment was marked as off-topic.

@aojea
Copy link
Copy Markdown
Member

aojea commented Apr 2, 2026

troublemaker ricardo 😄

@dims
Copy link
Copy Markdown
Member

dims commented Apr 2, 2026

thanks @rikatz this was a lot of fun :)

[package]
name = "safer-api-server"
version = "0.1.0"
edition = "2021"
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh I found a bug!!! The year is wrong!

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good catch!

let path = req.uri().path().to_string();

eprintln!(
"\x1b[32m[SAFER]\x1b[0m {} {} -> proxying to unsafe Go server (yikes)",
Copy link
Copy Markdown

@k-burt-uch k-burt-uch Apr 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider proxying to a safe rust server

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh! If the Rust servers are chained in several proxy layers then it must be more secure in the end, right?
Good idea!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/kubelet cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. needs-priority Indicates a PR lacks a `priority/foo` label and requires one. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. release-note-none Denotes a PR that doesn't merit a release note. sig/node Categorizes an issue or PR as relevant to SIG Node. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.

Development

Successfully merging this pull request may close these issues.