- Notifications
You must be signed in to change notification settings - Fork25
operator-framework/java-operator-plugins
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
This project is a component of theOperator Framework, anopen source toolkit to manage Kubernetes native applications, calledOperators, in an effective, automated, and scalable way. Read more intheintroduction blog post.
Operators make it easy to manage complex statefulapplications on top of Kubernetes. However writing an operator today canbe difficult because of challenges such as using low level APIs, writingboilerplate, and a lack of modularity which leads to duplication.
Operator SDK is under Apache 2.0 license. See theLICENSE file for details.
To use java-operator-plugins for java operators we need to clone the operator-sdk repo.
- Add the kubebuilder plugin to
go.mod
github.com/operator-framework/java-operator-plugins v0.0.0-20210225171707-e42ea87455e3- Replace the java-operator-plugins path in go-mod pointing to the local dir of your kube-builder repo. Example.
github.com/operator-framework/java-operator-plugins => /Users/sushah/go/src/github.com/sujil02/java-operator-plugins- Add the java-operator-sdk import
quarkusv1 "github.com/operator-framework/java-operator-plugins/pkg/quarkus/v1alpha"- Introduce the java bundle in
GetPluginsCLIAndRoot()method.
quarkusBundle, _ := plugin.NewBundle("quarkus"+plugins.DefaultNameQualifier, plugin.Version{Number: 1},&quarkusv1.Plugin{},)- Add the created quarkusBundle to the
cli.New
cli.WithPlugins(ansibleBundle,gov2Bundle,gov3Bundle,helmBundle,quarkusBundle,),go mod tidymake installNow that the plugin is integrated with theoperator-sdk you can run theinit command to generate the sample java operator
- Use the quarkus plugin flag
- Pick the domain and project name as prefered.
operator-sdk init --plugins quarkus --domain xyz.com --project-name java-opOnce the operator is scaffolded check for the following files
├── PROJECT├── pom.xml└── src └── main ├── java │ └── com │ └── xyz │ └── JavaOpOperator.java └── resources └── application.propertiesAbout
Operator SDK Java Plugin
Resources
License
Code of conduct
Contributing
Security policy
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
Uh oh!
There was an error while loading.Please reload this page.