83 lines
1.7 KiB
YAML
83 lines
1.7 KiB
YAML
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
labels:
|
|
kubeless: nats-trigger-controller
|
|
name: nats-trigger-controller
|
|
namespace: kubeless
|
|
spec:
|
|
selector:
|
|
matchLabels:
|
|
kubeless: nats-trigger-controller
|
|
template:
|
|
metadata:
|
|
labels:
|
|
kubeless: nats-trigger-controller
|
|
spec:
|
|
containers:
|
|
- env:
|
|
- name: NATS_URL
|
|
value: nats://message-queue.default.svc.cluster.local:4222
|
|
- name: KUBELESS_NAMESPACE
|
|
valueFrom:
|
|
fieldRef:
|
|
fieldPath: metadata.namespace
|
|
- name: KUBELESS_CONFIG
|
|
value: kubeless-config
|
|
image: kubeless/nats-trigger-controller:v1.0.0
|
|
imagePullPolicy: IfNotPresent
|
|
name: nats-trigger-controller
|
|
serviceAccountName: controller-acct
|
|
---
|
|
apiVersion: rbac.authorization.k8s.io/v1beta1
|
|
kind: ClusterRole
|
|
metadata:
|
|
name: nats-controller-deployer
|
|
rules:
|
|
- apiGroups:
|
|
- ""
|
|
resources:
|
|
- services
|
|
- configmaps
|
|
verbs:
|
|
- get
|
|
- list
|
|
- apiGroups:
|
|
- kubeless.io
|
|
resources:
|
|
- functions
|
|
- natstriggers
|
|
verbs:
|
|
- get
|
|
- list
|
|
- watch
|
|
- update
|
|
- delete
|
|
---
|
|
apiVersion: rbac.authorization.k8s.io/v1beta1
|
|
kind: ClusterRoleBinding
|
|
metadata:
|
|
name: nats-controller-deployer
|
|
roleRef:
|
|
apiGroup: rbac.authorization.k8s.io
|
|
kind: ClusterRole
|
|
name: nats-controller-deployer
|
|
subjects:
|
|
- kind: ServiceAccount
|
|
name: controller-acct
|
|
namespace: kubeless
|
|
---
|
|
apiVersion: apiextensions.k8s.io/v1beta1
|
|
kind: CustomResourceDefinition
|
|
metadata:
|
|
name: natstriggers.kubeless.io
|
|
spec:
|
|
group: kubeless.io
|
|
names:
|
|
kind: NATSTrigger
|
|
plural: natstriggers
|
|
singular: natstrigger
|
|
scope: Namespaced
|
|
version: v1beta1
|