---
# Source: manager-operator/templates/configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  name: manager-operator-cm
  namespace: ${NAMESPACE}
data:
  enableMonitoring: "false"
  sendAnnounce: "false"
---
# Source: manager-operator/templates/serviceaccount.yaml
apiVersion: v1
kind: ServiceAccount
metadata:
  name: manager-operator-sa
  namespace: ${NAMESPACE}
---
# Source: manager-operator/templates/clusterrole.yaml
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
  name: manager-operator-cr
rules:
- apiGroups:
  - ""
  resources:
  - configmaps
  - secrets
  - serviceaccounts
  - services
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - ""
  resources:
  - events
  verbs:
  - create
  - patch
- apiGroups:
  - ""
  resources:
  - namespaces
  - pods
  verbs:
  - get
  - list
  - watch
- apiGroups:
  - '*'
  resources:
  - nodes
  verbs:
  - get
  - list
  - watch
- apiGroups:
  - announce.manager.cubbit.io
  resources:
  - announces
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - announce.manager.cubbit.io
  resources:
  - announces/finalizers
  verbs:
  - update
- apiGroups:
  - announce.manager.cubbit.io
  resources:
  - announces/status
  verbs:
  - get
  - patch
  - update
- apiGroups:
  - apiextensions.k8s.io
  resources:
  - customresourcedefinitions
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - apps
  resources:
  - daemonsets
  - deployments
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - apps
  resources:
  - deployments/status
  verbs:
  - get
  - patch
  - update
- apiGroups:
  - batch
  resources:
  - cronjobs
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - cert-manager.io
  resources:
  - certificates
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - coordination.k8s.io
  resources:
  - leases
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - external-secrets.io
  resources:
  - externalsecrets
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - externaldns.k8s.io
  resources:
  - dnsendpoints
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - gateway.cubbit.io
  resources:
  - gateways
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - gateway.cubbit.io
  resources:
  - gateways/finalizers
  verbs:
  - update
- apiGroups:
  - gateway.cubbit.io
  resources:
  - gateways/status
  verbs:
  - get
  - patch
  - update
- apiGroups:
  - networking.k8s.io
  resources:
  - ingresses
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - offloader.cubbit.io
  resources:
  - offloaders
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - offloader.cubbit.io
  resources:
  - offloaders/finalizers
  verbs:
  - update
- apiGroups:
  - offloader.cubbit.io
  resources:
  - offloaders/status
  verbs:
  - get
  - patch
  - update
- apiGroups:
  - profile.manager.cubbit.io
  resources:
  - profilegateways
  - profilenodescanners
  - profileoffloaders
  - profileproxies
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - profile.manager.cubbit.io
  resources:
  - profilegateways/finalizers
  - profilenodescanners/finalizers
  - profileoffloaders/finalizers
  - profileproxies/finalizers
  verbs:
  - update
- apiGroups:
  - profile.manager.cubbit.io
  resources:
  - profilegateways/status
  - profilenodescanners/status
  - profileoffloaders/status
  - profileproxies/status
  verbs:
  - get
  - patch
  - update
- apiGroups:
  - rbac.authorization.k8s.io
  resources:
  - clusterrolebindings
  - clusterroles
  - rolebindings
  - roles
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - tenant.cubbit.io
  resources:
  - tenants
  verbs:
  - create
  - delete
  - get
  - list
  - patch
  - update
  - watch
- apiGroups:
  - tenant.cubbit.io
  resources:
  - tenants/finalizers
  verbs:
  - update
- apiGroups:
  - tenant.cubbit.io
  resources:
  - tenants/status
  verbs:
  - get
  - patch
  - update
---
# Source: manager-operator/templates/rolebinding.yaml
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
  name: manager-operator-crb
roleRef:
  apiGroup: rbac.authorization.k8s.io
  kind: ClusterRole
  name: manager-operator-cr
subjects:
- kind: ServiceAccount
  name: manager-operator-sa
  namespace: "${NAMESPACE}"
---
# Source: manager-operator/templates/deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app.kubernetes.io/app-name: manager-operator
  name: manager-operator
spec:
  replicas: 1
  selector:
    matchLabels:
      name: manager-operator
  template:
    metadata:
      labels:
        name: manager-operator
    spec:
      imagePullSecrets:
        - name: regcred
      serviceAccountName: manager-operator-sa
      securityContext:
        runAsNonRoot: true
      containers:
      - name: manager-operator
        image: cubbit/manager-operator:demo-2507
        imagePullPolicy: "Always"
        command:
        - /manager
        args:
        - --health-probe-bind-address=:8081
        - --metrics-bind-address=127.0.0.1:8080
        - --leader-elect
        - --zap-log-level=DEBUG
        securityContext:
          allowPrivilegeEscalation: false
          capabilities:
            drop:
              - "ALL"
        livenessProbe:
          httpGet:
            path: /healthz
            port: 8081
          initialDelaySeconds: 15
          periodSeconds: 20
        readinessProbe:
          httpGet:
            path: /readyz
            port: 8081
          initialDelaySeconds: 5
          periodSeconds: 10
        env:
          - name: WATCH_NAMESPACE
            valueFrom:
              fieldRef:
                fieldPath: metadata.namespace
        resources:
          limits:
            cpu: 500m
            memory: 128Mi
          requests:
            cpu: 10m
            memory: 64Mi
      terminationGracePeriodSeconds: 10
---
