disable mongodb-operator
This commit is contained in:
21
_disabled/mongodb-operator/README.md
Normal file
21
_disabled/mongodb-operator/README.md
Normal file
@@ -0,0 +1,21 @@
|
||||
# MongoDB Community Kubernetes Operator
|
||||
|
||||
## Derployment
|
||||
|
||||
With ArgoCD. Render it locally:
|
||||
|
||||
```sh
|
||||
kustomize build . --enable-helm
|
||||
```
|
||||
|
||||
# Instantiating databases
|
||||
For each application include mongodb-netpol.yaml and kustomization in resources:
|
||||
```yaml
|
||||
resources:
|
||||
- https://git.k-space.ee/k-space/kube//mongodb-operator/mongodb-netpol.yaml
|
||||
- https://github.com/mongodb/mongodb-kubernetes-operator//config/rbac/?ref=v0.13.0
|
||||
```
|
||||
|
||||
```
|
||||
kubectl create secret generic -n <application> mongodb-application-user-password --from-literal="password=$(cat /dev/urandom | base64 | head -c 30)"
|
||||
```
|
13
_disabled/mongodb-operator/kustomization.yaml
Normal file
13
_disabled/mongodb-operator/kustomization.yaml
Normal file
@@ -0,0 +1,13 @@
|
||||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
namespace: mongodb-operator
|
||||
|
||||
# spec: https://kubectl.docs.kubernetes.io/references/kustomize/builtins/#_helmchartinflationgenerator_
|
||||
helmCharts:
|
||||
- includeCRDs: true
|
||||
name: &name community-operator
|
||||
releaseName: *name
|
||||
repo: https://mongodb.github.io/helm-charts
|
||||
valuesFile: values.yaml
|
||||
version: 0.13.0 # helm search repo mongodb/community-operator --versions
|
25
_disabled/mongodb-operator/mongodb-netpol.yml
Normal file
25
_disabled/mongodb-operator/mongodb-netpol.yml
Normal file
@@ -0,0 +1,25 @@
|
||||
# Allow any pod in this namespace to connect to MongoDB and
|
||||
# allow cluster members to talk to eachother
|
||||
apiVersion: networking.k8s.io/v1
|
||||
kind: NetworkPolicy
|
||||
metadata:
|
||||
name: mongodb-operator
|
||||
spec:
|
||||
podSelector:
|
||||
matchLabels:
|
||||
app: mongodb-svc
|
||||
policyTypes:
|
||||
- Ingress
|
||||
- Egress
|
||||
ingress:
|
||||
- from:
|
||||
- podSelector: {}
|
||||
ports:
|
||||
- port: 27017
|
||||
egress:
|
||||
- to:
|
||||
- podSelector:
|
||||
matchLabels:
|
||||
app: mongodb-svc
|
||||
ports:
|
||||
- port: 27017
|
2
_disabled/mongodb-operator/values.yaml
Normal file
2
_disabled/mongodb-operator/values.yaml
Normal file
@@ -0,0 +1,2 @@
|
||||
operator:
|
||||
watchNamespace: '*'
|
Reference in New Issue
Block a user