-
Notifications
You must be signed in to change notification settings - Fork 2
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
Fork helm-operator adjustments for CI and documentation #4
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
upstream-triage: | ||
- "./*" | ||
area/main-binary: | ||
- 'main.go' | ||
- 'internal/**/*' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,7 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- '**' | ||
pull_request: | ||
branches: [ main ] | ||
- push | ||
|
||
jobs: | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,46 @@ | ||
# helm-operator | ||
|
||
[![Build Status](https://github.com/joelanford/helm-operator/workflows/CI/badge.svg?branch=master) | ||
[![Coverage Status](https://coveralls.io/repos/github/joelanford/helm-operator/badge.svg?branch=master)](https://coveralls.io/github/joelanford/helm-operator?branch=master) | ||
[![Build Status](https://github.com/stackrox/helm-operator/workflows/CI/badge.svg?branch=main) | ||
|
||
Experimental refactoring of the operator-framework's helm operator | ||
|
||
## Why a fork? | ||
|
||
Initially the Helm operator type was designed to automate Helm chart operations | ||
by mapping the [values](https://helm.sh/docs/chart_template_guide/values_files/) of a Helm chart exactly to a | ||
`CustomResourceDefinition` and defining its watched resources in a `watches.yaml` | ||
[configuration](https://sdk.operatorframework.io/docs/building-operators/helm/tutorial/#watch-the-nginx-cr). | ||
|
||
To write a [Level II+](https://sdk.operatorframework.io/docs/advanced-topics/operator-capabilities/operator-capabilities/) operator | ||
which reuses an already existing Helm chart a [hybrid](https://github.com/operator-framework/operator-sdk/issues/670) | ||
between the Go and Helm operator type is necessary. | ||
|
||
The hybrid approach allows to add customizations to the Helm operator like value mapping based on cluster state or | ||
executing code in on specific events. | ||
|
||
## Quickstart | ||
|
||
Add this module as a replace directive to your `go.mod`: | ||
|
||
``` | ||
go mod edit -replace=github.com/joelanford/helm-operator=github.com/stackrox/helm-operator@main | ||
``` | ||
|
||
Example: | ||
|
||
``` | ||
chart, err := loader.Load("path/to/chart") | ||
if err != nil { | ||
panic(err) | ||
} | ||
|
||
reconciler := reconciler.New( | ||
reconciler.WithChart(*chart), | ||
reconciler.WithGroupVersionKind(gvk), | ||
) | ||
|
||
if err := reconciler.SetupWithManager(mgr); err != nil { | ||
panic(fmt.Sprintf("unable to create reconciler: %s", err)) | ||
} | ||
``` | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Curious as to why you changed this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because the CI was not triggered in the default setting.