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

addon hbase-operator #652

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
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
Binary file not shown.
1 change: 1 addition & 0 deletions experimental/addons/hbase-operator/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
#will be filled at the end
63 changes: 63 additions & 0 deletions experimental/addons/hbase-operator/definations/hbse-cluster.cue
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
"hbase-cluster": {
alias: ""
annotations: {}
attributes: workload: type: "autodetects.core.oam.dev"
description: "hbase-cluster component"
labels: {}
type: "component"
}

template: {
output: {
kind: "HBASECluster"
apiVersion: "hbase.stackable.tech/v1alpha1"
metadata: {
name: context.name
}
spec: {
image: parameter.image
config: parameter.config
hdfsConfigMapName: *null | string
zookeeperConfigMapName: *null | string
masters: parameter.masters
regionServers: parameter.regionServers
restServers: parameter.restServers

}
}
parameter: {
//+usage=The Hive metastore image to use.
image: {
//+usage=Overwrite the docker image. Specify the full docker image name, e.g. `docker.stackable.tech/stackable/superset:1.4.1-stackable2.1.0
custom: *null | string
//+usage=Version of the product, e.g. `1.4.1`.
productVersion: *null | string
//+usage=Pull policy used when pulling the Images.
pullPolicy: *"IfNotPresent" | string
//+usage=Image pull secrets to pull images from a private registry.
pullSecrets: *null | [...]
//+usage=Name of the docker repo, e.g. `docker.stackable.tech/stackable.
repo: *null | string
//+usage=Stackable version of the product, e.g. 2.1.0.
stackableVersion: *null | string
}
//+usage=General Hive metastore cluster settings.
config: {


hbaseOpts: *null | string
hbaseRootdir: *null | string

}
master: {
roleGroups: *{} | {...}
}

regionServers: {
roleGroups: *{} | {...}
}
restServers: {
roleGroups: *{} | {...}
}


Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
"zookeperznode-cluster": {
alias: ""
annotations: {}
attributes: workload: type: "autodetects.core.oam.dev"
description: "s3 bucket component"
labels: {}
type: "component"
}

template: {
output: {
kind: "ZookeeperZnode"
apiVersion: "zookeeper.stackable.tech/v1alpha1"
metadata: {
name: context.name
}
spec: {
clusterRef: parameter.clusterRef
}
}
parameter: {
clusterRef: {
name: *null | string
}

}
13 changes: 13 additions & 0 deletions experimental/addons/hbase-operator/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: hbase-operator
version: 1.0.0
description: This addon adds hbase-operator to the kubevela to be used by across the application installed in kubevela.
icon: ""
url: "https://hbase.apache.org/"

tags:
- hbase-operator

invisible: false

dependencies:
- name: fluxcd
11 changes: 11 additions & 0 deletions experimental/addons/hbase-operator/parameter.cue
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
// parameter.cue is used to store addon parameters.
//
// You can use these parameters in template.cue or in resources/ by 'parameter.myparam'
//
// For example, you can use parameters to allow the user to customize
// container images, ports, and etc.
parameter: {
// +usage=Custom parameter description
namespace: *"hbase-operator" | string
clusters?: [...string]
}
95 changes: 95 additions & 0 deletions experimental/addons/hbase-operator/template.cue
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
package main
output: {
apiVersion: "core.oam.dev/v1beta1"
kind: "Application"
spec: {
components: [
{
name: "ns-hbase-operator"
type: "k8s-objects"
properties: objects: [{
kind: "Namespace"
apiVersion: "v1"
metadata:
name: parameter.namespace
}]
},
{
name: "hbase-operator"
type: "helm"
properties: {
repoType: "helm"
url: "https://repo.stackable.tech/repository/helm-stable/stackable-stable"
chart: "hbase-operator"
version: "23.1.0"
}
},
{
name: "zookeeper-operator"
type: "helm"
properties: {
repoType: "helm"
url: "https://repo.stackable.tech/repository/helm-stable/stackable-stable"
chart: "zookeeper-operator"
version: "23.1.0"
}
},
{
name: "hdfs-operator"
type: "helm"
properties: {
repoType: "helm"
url: "https://repo.stackable.tech/repository/helm-stable/stackable-stable"
chart: "hdfs-operator"
version: "23.1.0"
}
},
{
name: "commons-operator"
type: "helm"
properties: {
repoType: "helm"
url: "https://repo.stackable.tech/repository/helm-stable/stackable-stable"
chart: "commons-operator"
version: "23.1.0"
}
},
{
name: "secret-operator"
type: "helm"
properties: {
repoType: "helm"
url: "https://repo.stackable.tech/repository/helm-stable/stackable-stable"
chart: "secret-operator"
version: "23.1.0"
}
},
]
policies: [
{
type: "shared-resource"
name: "hbase-operator-ns"
properties: rules: [{
selector: resourceTypes: ["Namespace"]
}]
},
{
type: "topology"
name: "deploy-hbase-operator"
properties: {
namespace: parameter.namespace
if parameter.clusters != _|_ {
clusters: parameter.clusters
}
if parameter.clusters == _|_ {
clusterLabelSelector: {}
}
}
},
]
}
}