A Rust-based plugin for the Operator SDK that helps you scaffold Kubernetes Operators with Rust. This project aims to simplify and enhance the development experience for Kubernetes operators written in Rust.
- An Operator SDK plugin to enable scaffolding, building, and testing (coming soon) Kubernetes operators with Rust.
- Supports common Kubernetes resources like CRDs, and controllers.
- Customizable templates and scaffolding for different operator components.
- Designed with the goal of improving the developer experience for Rust developers in the Kubernetes ecosystem.
- https://www.youtube.com/watch?v=2q3RLffSvEc
- https://www.youtube.com/watch?v=rXS-3hFYVjc
- https://www.youtube.com/watch?v=Z8ciQpsQc4E&list=PLj6h78yzYM2MKPAas7pxIvueTbwFqVRCX
Ensure that you have the following installed on your system:
To install this Rust Operator SDK plugin, use the following steps:
-
Clone the repository:
git clone https://github.com/SystemCraftsman/rust-operator-plugins.git cd rust-operator-plugins
-
Initialize the Operator SDK within the project:
make init-sdk
This fetches a required version of the Operator SDK, configures it for local development.
-
Build the plugin:
make build
This comamnd builds Operator SDK with the Rust Operator Plugin included.
-
Install the plugin (for local development):
make install
This installs an Operator SDK binary with the Rust Operator Plugin.
-
You should now be able to use the plugin with the Operator SDK CLI.
Once installed, you can use this plugin with the operator-sdk
command-line tool to initialize a new operator project
written in Rust.
Following is an example of initializing the operator in your <project_directory>
:
cd <project_directory>
operator-sdk init --plugins rust/v1alpha --domain <your-domain>
To create a new API with resources and the controllers scaffolded, you should run a command as follows:
operator-sdk create api --group <your-api-group> --version <api-version> --kind <crd-name> --resource --controller
Additionally, you can create the resource
and controller
with separate commands.