Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tutorial on hybrid helm based operators #149

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions docs/Welcome.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Helm Operator Plugins

This repository contains the plugins and required APIs for Helm related projects. There are two plugins present here:

1. Traditional Helm Operator Plugin
2. Hybrid Helm Operator plugin

## Motivation behind Hybrid Helm plugin

The traditional [Helm operator][helm_sdk] operator has limited functionality compared to Golang or Ansible operators which have reached [Operator Capability level V][capability_level]. The Hybrid Helm operator enhances the existing Helm operator's abilities through Go APIs. With the hybrid approach operator authors can:

1. Scaffold a Go API in the same project as Helm.
2. Configure the Helm reconciler in `main.go` of the project, through the libraries provided in this repository.

[helm_sdk]: https://sdk.operatorframework.io/docs/building-operators/helm/
[capability_level]: https://sdk.operatorframework.io/docs/overview/operator-capabilities/
25 changes: 25 additions & 0 deletions docs/project_layout.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Project Layout

The Hybrid Helm project's scaffolding is customized to be compatible with both Helm and Go APIs.

| File/Directory | Description |
| ------ | ----- |
| `Dockerfile` | The Dockerfile of your operator project, used to build the image with `make docker-build`. |
| `Makefile` | Build file with helper targets to help you work with your project. |
| `PROJECT` | This file represents the project's configuration and is used to track useful information for the CLI and plugins. |
| `bin/` | This directory contains useful binaries such as the `manager` which is used to run your project locally and the `kustomize` utility used for the project configuration. |
| `config/` | Contains configuration files to launch your project on a cluster. Plugins might use it to provide functionality. For example, for the CLI to help create your operator bundle it will look for the CRD's and CR's which are scaffolded in this directory. You will also find all [Kustomize][Kustomize] YAML definitions as well. |
| `config/crd/` | Contains the [Custom Resources Definitions][k8s-crd-doc]. |
| `config/default/` | Contains a [Kustomize base][kustomize-base] for launching the controller in a standard configuration. |
| `config/manager/` | Contains the manifests to launch your operator project as pods on the cluster. |
| `config/manifests/` | Contains the base to generate your OLM manifests in the bundle directory. |
| `config/prometheus/` | Contains the manifests required to enable project to serve metrics to [Prometheus][kb-metrics] such as the `ServiceMonitor` resource. |
| `config/scorecard/` | Contains the manifests required to allow you test your project with [Scorecard][scorecard]. |
| `config/rbac/` | Contains the [RBAC][k8s-rbac] permissions required to run your project. |
| `config/samples/` | Contains the [Custom Resources][k8s-cr-doc]. |
|`api/` | Contains the Go api definition |
|`controllers` | Contains the controllers for Go API |
| `hack/` | Contains utility files, e.g. the file used to scaffold the license header for your project files. |
|`main.go` | Implements the project initialization |
|`helm-charts` | Contains the Helm charts which can be specified using `create api` command of helm plugin |
|`watches.yaml` | Contains Group, Version, Kind, and Helm chart location. Used to configure the [Helm watches][helm-watches]. |
varshaprasad96 marked this conversation as resolved.
Show resolved Hide resolved
Loading