In the world of Kubernetes, most programs extending Kubernetes are written in Go, and most applications orchestrated by Kubernetes are packaged as containers. These two things have become so common as to have become default, but neither is expressly necessary, as proven by an up and coming project out of  Microsoft’s Deis Labs called  Krustlet, which is currently  in the process of joining the  Cloud Native Computing Foundation (CNCF) at the Sandbox level.

Krustlet upends both of these Kubernetes customs, first in that it is written in Rust, the notably memory-safe language originally developed by Mozilla, and second in that its purpose is to enable Kubernetes to schedule WebAssembly modules in lieu of  Open Container Initiative (OCI) containers. While the Krustlet team was  careful to note during its launch a little over a year ago that WebAssembly and containers can act as “a complementary pair,” each with “their own set of unique advantages and disadvantages,” it is precisely those advantages they wanted to bring to Kubernetes.

“WebAssembly can do many of the same tasks that a container does, but it has a different operational profile. It can be run with far fewer privileges, it is smaller, and it is cross-architecture/cross-OS,” explained  Matt Butcher, a principal software engineer with Azure Core in an email. “Being familiar with Kubernetes, we wanted to see if we could build a tool that executes Wasm inside of Kubernetes to illustrate the similarities and highlight the differences between Wasm and containers. That turned out to be a watershed moment. WebAssembly is showing even more promise than we originally imagined.”

According to  Ralph Squillace, a principal program manager for Azure Core, there was another reason to bring WebAssembly to Kubernetes, as well.

“The driving power of the Kubernetes project was not so much in the container runtimes — even though they kickstarted the revolution — but in the control plane, the API that unifies the skillset and the tooling,” wrote Squillace in an email. “We wanted to see what could be done using a different sandboxed process approach (WASM) with that operational model — where could that go? Turns out, it goes well.”

#containers #development #kubernetes #webassembly

Krustlet Brings WebAssembly to Kubernetes with a Rust-Based Kubelet
1.15 GEEK