generated from onedr0p/cluster-template
-
-
Notifications
You must be signed in to change notification settings - Fork 0
feat(kubernetes): install openebs #566
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
Merged
Merged
Conversation
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
--- kubernetes/apps/flux-system/addons/notifications Kustomization: flux-system/flux-notifications Alert: flux-system/alertmanager
+++ kubernetes/apps/flux-system/addons/notifications Kustomization: flux-system/flux-notifications Alert: flux-system/alertmanager
@@ -45,12 +45,15 @@
namespace: monitoring
- kind: HelmRelease
name: '*'
namespace: networking
- kind: HelmRelease
name: '*'
+ namespace: openebs-system
+ - kind: HelmRelease
+ name: '*'
namespace: system-upgrade
- kind: HelmRelease
name: '*'
namespace: volsync
- kind: HelmRepository
name: '*'
--- kubernetes/flux Kustomization: flux-system/cluster HelmRepository: flux-system/openebs
+++ kubernetes/flux Kustomization: flux-system/cluster HelmRepository: flux-system/openebs
@@ -0,0 +1,13 @@
+---
+apiVersion: source.toolkit.fluxcd.io/v1beta2
+kind: HelmRepository
+metadata:
+ labels:
+ kustomize.toolkit.fluxcd.io/name: cluster
+ kustomize.toolkit.fluxcd.io/namespace: flux-system
+ name: openebs
+ namespace: flux-system
+spec:
+ interval: 2h
+ url: https://openebs.github.io/charts
+
--- kubernetes/apps Kustomization: flux-system/cluster-apps Namespace: flux-system/openebs-system
+++ kubernetes/apps Kustomization: flux-system/cluster-apps Namespace: flux-system/openebs-system
@@ -0,0 +1,11 @@
+---
+apiVersion: v1
+kind: Namespace
+metadata:
+ annotations:
+ kustomize.toolkit.fluxcd.io/prune: disabled
+ labels:
+ kustomize.toolkit.fluxcd.io/name: cluster-apps
+ kustomize.toolkit.fluxcd.io/namespace: flux-system
+ name: openebs-system
+
--- kubernetes/apps Kustomization: flux-system/cluster-apps Kustomization: flux-system/openebs
+++ kubernetes/apps Kustomization: flux-system/cluster-apps Kustomization: flux-system/openebs
@@ -0,0 +1,34 @@
+---
+apiVersion: kustomize.toolkit.fluxcd.io/v1
+kind: Kustomization
+metadata:
+ labels:
+ kustomize.toolkit.fluxcd.io/name: cluster-apps
+ kustomize.toolkit.fluxcd.io/namespace: flux-system
+ name: openebs
+ namespace: flux-system
+spec:
+ commonMetadata:
+ labels:
+ app.kubernetes.io/name: openebs
+ decryption:
+ provider: sops
+ secretRef:
+ name: sops-age
+ interval: 2h
+ path: ./kubernetes/apps/openebs-system/openebs/app
+ postBuild:
+ substituteFrom:
+ - kind: ConfigMap
+ name: cluster-settings
+ - kind: Secret
+ name: cluster-secrets
+ prune: true
+ retryInterval: 1m
+ sourceRef:
+ kind: GitRepository
+ name: home-kubernetes
+ targetNamespace: openebs-system
+ timeout: 5m
+ wait: false
+
--- kubernetes/apps/openebs-system/openebs/app Kustomization: flux-system/openebs HelmRelease: openebs-system/openebs
+++ kubernetes/apps/openebs-system/openebs/app Kustomization: flux-system/openebs HelmRelease: openebs-system/openebs
@@ -0,0 +1,44 @@
+---
+apiVersion: helm.toolkit.fluxcd.io/v2beta2
+kind: HelmRelease
+metadata:
+ labels:
+ app.kubernetes.io/name: openebs
+ kustomize.toolkit.fluxcd.io/name: openebs
+ kustomize.toolkit.fluxcd.io/namespace: flux-system
+ name: openebs
+ namespace: openebs-system
+spec:
+ chart:
+ spec:
+ chart: openebs
+ sourceRef:
+ kind: HelmRepository
+ name: openebs
+ namespace: flux-system
+ version: 3.10.0
+ install:
+ remediation:
+ retries: 3
+ interval: 30m
+ upgrade:
+ cleanupOnFail: true
+ remediation:
+ retries: 3
+ strategy: rollback
+ values:
+ localprovisioner:
+ deviceClass:
+ enabled: false
+ enabled: true
+ hostpathClass:
+ basePath: /var/openebs/local
+ enabled: true
+ isDefaultClass: false
+ name: openebs-hostpath
+ image: quay.io/openebs/provisioner-localpv
+ ndm:
+ enabled: false
+ ndmOperator:
+ enabled: false
+ |
--- HelmRelease: openebs-system/openebs ServiceAccount: openebs-system/openebs
+++ HelmRelease: openebs-system/openebs ServiceAccount: openebs-system/openebs
@@ -0,0 +1,10 @@
+---
+apiVersion: v1
+kind: ServiceAccount
+metadata:
+ name: openebs
+ labels:
+ app: openebs
+ release: openebs
+ heritage: Helm
+
--- HelmRelease: openebs-system/openebs StorageClass: openebs-system/openebs-hostpath
+++ HelmRelease: openebs-system/openebs StorageClass: openebs-system/openebs-hostpath
@@ -0,0 +1,16 @@
+---
+apiVersion: storage.k8s.io/v1
+kind: StorageClass
+metadata:
+ name: openebs-hostpath
+ annotations:
+ openebs.io/cas-type: local
+ cas.openebs.io/config: |
+ - name: StorageType
+ value: "hostpath"
+ - name: BasePath
+ value: "/var/openebs/local"
+provisioner: openebs.io/local
+volumeBindingMode: WaitForFirstConsumer
+reclaimPolicy: Delete
+
--- HelmRelease: openebs-system/openebs ClusterRole: openebs-system/openebs
+++ HelmRelease: openebs-system/openebs ClusterRole: openebs-system/openebs
@@ -0,0 +1,142 @@
+---
+apiVersion: rbac.authorization.k8s.io/v1
+kind: ClusterRole
+metadata:
+ name: openebs
+ labels:
+ app: openebs
+ release: openebs
+ heritage: Helm
+rules:
+- apiGroups:
+ - '*'
+ resources:
+ - nodes
+ - nodes/proxy
+ verbs:
+ - '*'
+- apiGroups:
+ - '*'
+ resources:
+ - namespaces
+ - services
+ - pods
+ - pods/exec
+ - deployments
+ - deployments/finalizers
+ - replicationcontrollers
+ - replicasets
+ - events
+ - endpoints
+ - configmaps
+ - secrets
+ - jobs
+ - cronjobs
+ verbs:
+ - '*'
+- apiGroups:
+ - '*'
+ resources:
+ - statefulsets
+ - daemonsets
+ verbs:
+ - '*'
+- apiGroups:
+ - '*'
+ resources:
+ - resourcequotas
+ - limitranges
+ verbs:
+ - list
+ - watch
+- apiGroups:
+ - '*'
+ resources:
+ - ingresses
+ - horizontalpodautoscalers
+ - verticalpodautoscalers
+ - poddisruptionbudgets
+ - certificatesigningrequests
+ verbs:
+ - list
+ - watch
+- apiGroups:
+ - '*'
+ resources:
+ - storageclasses
+ - persistentvolumeclaims
+ - persistentvolumes
+ verbs:
+ - '*'
+- apiGroups:
+ - volumesnapshot.external-storage.k8s.io
+ resources:
+ - volumesnapshots
+ - volumesnapshotdatas
+ verbs:
+ - get
+ - list
+ - watch
+ - create
+ - update
+ - patch
+ - delete
+- apiGroups:
+ - apiextensions.k8s.io
+ resources:
+ - customresourcedefinitions
+ verbs:
+ - get
+ - list
+ - create
+ - update
+ - delete
+ - patch
+- apiGroups:
+ - openebs.io
+ resources:
+ - '*'
+ verbs:
+ - '*'
+- apiGroups:
+ - cstor.openebs.io
+ resources:
+ - '*'
+ verbs:
+ - '*'
+- apiGroups:
+ - coordination.k8s.io
+ resources:
+ - leases
+ verbs:
+ - get
+ - watch
+ - list
+ - delete
+ - update
+ - create
+- apiGroups:
+ - admissionregistration.k8s.io
+ resources:
+ - validatingwebhookconfigurations
+ - mutatingwebhookconfigurations
+ verbs:
+ - get
+ - create
+ - list
+ - delete
+ - update
+ - patch
+- apiGroups:
+ - coordination.k8s.io
+ resources:
+ - leases
+ verbs:
+ - get
+ - create
+ - update
+- nonResourceURLs:
+ - /metrics
+ verbs:
+ - get
+
--- HelmRelease: openebs-system/openebs ClusterRoleBinding: openebs-system/openebs
+++ HelmRelease: openebs-system/openebs ClusterRoleBinding: openebs-system/openebs
@@ -0,0 +1,18 @@
+---
+apiVersion: rbac.authorization.k8s.io/v1
+kind: ClusterRoleBinding
+metadata:
+ name: openebs
+ labels:
+ app: openebs
+ release: openebs
+ heritage: Helm
+roleRef:
+ apiGroup: rbac.authorization.k8s.io
+ kind: ClusterRole
+ name: openebs
+subjects:
+- kind: ServiceAccount
+ name: openebs
+ namespace: openebs-system
+
--- HelmRelease: openebs-system/openebs Deployment: openebs-system/openebs-localpv-provisioner
+++ HelmRelease: openebs-system/openebs Deployment: openebs-system/openebs-localpv-provisioner
@@ -0,0 +1,70 @@
+---
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+ name: openebs-localpv-provisioner
+ labels:
+ app: openebs
+ release: openebs
+ heritage: Helm
+ component: localpv-provisioner
+ openebs.io/component-name: openebs-localpv-provisioner
+ openebs.io/version: 3.10.0
+spec:
+ replicas: 1
+ strategy:
+ type: Recreate
+ rollingUpdate: null
+ selector:
+ matchLabels:
+ app: openebs
+ release: openebs
+ template:
+ metadata:
+ labels:
+ app: openebs
+ release: openebs
+ component: localpv-provisioner
+ name: openebs-localpv-provisioner
+ openebs.io/component-name: openebs-localpv-provisioner
+ openebs.io/version: 3.10.0
+ spec:
+ serviceAccountName: openebs
+ containers:
+ - name: openebs-localpv-provisioner
+ image: quay.io/openebs/provisioner-localpv:3.5.0
+ imagePullPolicy: IfNotPresent
+ args:
+ - --bd-time-out=$(BDC_BD_BIND_RETRIES)
+ env:
+ - name: BDC_BD_BIND_RETRIES
+ value: '12'
+ - name: OPENEBS_NAMESPACE
+ value: openebs-system
+ - name: NODE_NAME
+ valueFrom:
+ fieldRef:
+ fieldPath: spec.nodeName
+ - name: OPENEBS_SERVICE_ACCOUNT
+ valueFrom:
+ fieldRef:
+ fieldPath: spec.serviceAccountName
+ - name: OPENEBS_IO_ENABLE_ANALYTICS
+ value: 'true'
+ - name: OPENEBS_IO_BASE_PATH
+ value: /var/openebs/local
+ - name: OPENEBS_IO_HELPER_IMAGE
+ value: openebs/linux-utils:3.5.0
+ - name: OPENEBS_IO_INSTALLER_TYPE
+ value: charts-helm
+ - name: LEADER_ELECTION_ENABLED
+ value: 'true'
+ livenessProbe:
+ exec:
+ command:
+ - sh
+ - -c
+ - test `pgrep -c "^provisioner-loc.*"` = 1
+ initialDelaySeconds: 30
+ periodSeconds: 60
+ |
e7e6926
to
e2f4727
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
No description provided.