From aeac4bc46c30c66cfb1e622fe9b46a3299dc5190 Mon Sep 17 00:00:00 2001 From: Cedric Verstraeten Date: Sun, 11 Aug 2024 20:37:09 +0200 Subject: [PATCH] fix --- README.microk8s.md | 36 ++++++++++++++++++++++++- kerberos-agent-deployment.yaml | 48 ++++++++++++++++++---------------- 2 files changed, 61 insertions(+), 23 deletions(-) diff --git a/README.microk8s.md b/README.microk8s.md index 3ce110a..fbb8b7b 100644 --- a/README.microk8s.md +++ b/README.microk8s.md @@ -221,6 +221,7 @@ create the minio provider, add integration - Add storage provider - Minio + - Enabled: true - Provider name: minio - Bucket name: mybucket - Region: na @@ -231,6 +232,7 @@ create the minio provider, add integration - Add an integration - RabbitMQ + - Enabled: true - Integration name: rabbitmq - Broker: rabbitmq.rabbitmq:5672 - Exchange: @@ -239,6 +241,7 @@ create the minio provider, add integration - Password: yourpassword - Add an account + - Enabled: true - Account name: myaccount - Main provider: minio - Day limit: 30 @@ -249,6 +252,37 @@ create the minio provider, add integration ### Create an agent +Now we have deployed the Kerberos Vault and provided the correct configuration, and linked all the relevant services for storage, database and integrate, we can deploy the Kerberos Agent with the relevant configuration. Have a look in the `kerberos-agent-deployment.yaml` file and make sure to modify the relevant settings such as the RTSP url etc. + +```bash +kubectl apply -f kerberos-agent-deployment.yaml +``` + ### Create the data filtering -### add forwarding integration +The idea of filtering can have multiple reasons please check the repo here for more indepth information. + +```bash +kubectl apply -f data-filtering-deployment.yaml +``` + +### Add forwarding integration + +We'll need to access the UI again to add the integration + +```bash +ssh -L 8080:localhost:30080 user@server-ip -p 22 +``` + +Go to the Kerberos Vault application in your browser and open the integration section, add a new integration. + +- Add an integration + + - Kerberos Vault + - Enabled: true + - Integration name: rabbitmq + - Broker: rabbitmq.rabbitmq:5672 + - Exchange: + - Queue: data-filtering + - Username: yourusername + - Password: yourpassword diff --git a/kerberos-agent-deployment.yaml b/kerberos-agent-deployment.yaml index b71f896..e872989 100644 --- a/kerberos-agent-deployment.yaml +++ b/kerberos-agent-deployment.yaml @@ -1,21 +1,21 @@ apiVersion: apps/v1 kind: Deployment metadata: - name: agent + name: agent1 labels: - name: agent + name: agent1 spec: selector: matchLabels: - app: agent + app: agent1 replicas: 1 template: metadata: labels: - app: agent + app: agent1 spec: containers: - - name: agent + - name: agent1 image: kerberos/agent:latest ports: - containerPort: 80 @@ -28,18 +28,22 @@ spec: cpu: 100m memory: 128Mi env: + - name: AGENT_KEY + value: demo-agent1 - name: AGENT_NAME - value: demo-agent + value: demo-agent1 - name: AGENT_CAPTURE_IPCAMERA_RTSP value: rtsp://fake.kerberos.io/stream + - name: AGENT_CAPTURE_IPCAMERA_SUB_RTSP + value: rtsp://fake.kerberos.io/stream - name: AGENT_CLOUD value: kstorage - name: AGENT_KERBEROSVAULT_URI value: http://vault-lb.kerberos-vault/api - name: AGENT_KERBEROSVAULT_ACCESS_KEY - value: 52gyELgxutOXUWhF + value: XJoi2@bgSOvOYBy# - name: AGENT_KERBEROSVAULT_SECRET_KEY - value: k8DrcB@hQ5XfxDENzDKcnkxBHx + value: OGGqat4lXRpL@9XBYc8FUaId@5 - name: AGENT_KERBEROSVAULT_PROVIDER value: mybucket - name: AGENT_KERBEROSVAULT_DIRECTORY @@ -53,17 +57,17 @@ spec: - name: AGENT_HUB_PRIVATE_KEY value: xxx # find full list of environment variables here: https://github.com/kerberos-io/agent#override-with-environment-variables ---- -apiVersion: v1 -kind: Service -metadata: - name: agent-svc - labels: - name: agent-svc -spec: - type: LoadBalancer - ports: - - port: 80 - targetPort: 80 - selector: - app: agent \ No newline at end of file +#--- +#apiVersion: v1 +#kind: Service +#metadata: +# name: agent-svc +# labels: +# name: agent-svc +#spec: +# type: LoadBalancer +# ports: +# - port: 80 +# targetPort: 80 +# selector: +# app: agent \ No newline at end of file