From 429153524c96691ea09ad18738d4826806ad3120 Mon Sep 17 00:00:00 2001 From: wserr Date: Tue, 21 Jun 2022 23:05:19 +0200 Subject: [PATCH] Remove helm template --- Development.md | 45 ------------------ helm/Chart.yaml | 2 - helm/README.md | 3 -- helm/scripts/install.sh | 1 - helm/scripts/registry-secret.sh | 6 --- helm/scripts/uninstall.sh | 1 - helm/scripts/upgrade.sh | 1 - helm/templates/HomeAssistant/pv.yml | 21 -------- helm/templates/HomeAssistant/pvc.yml | 12 ----- helm/templates/HomeAssistant/service.yml | 14 ------ helm/templates/HomeAssistant/statefulset.yml | 28 ----------- helm/templates/MQTT/deployment.yml | 23 --------- helm/templates/MQTT/service.yml | 19 -------- helm/values-homeserver.yml | 11 ----- .../readme.md | 0 .../script.py | 0 .../test.jpg | Bin {RabbitMQ => rabbitmq}/Dockerfile | 0 {RabbitMQ => rabbitmq}/push.sh | 0 README.md => readme.md | 0 Server.md => server.md | 0 VPN.md => vpn.md | 0 22 files changed, 187 deletions(-) delete mode 100644 Development.md delete mode 100644 helm/Chart.yaml delete mode 100644 helm/README.md delete mode 100755 helm/scripts/install.sh delete mode 100755 helm/scripts/registry-secret.sh delete mode 100755 helm/scripts/uninstall.sh delete mode 100755 helm/scripts/upgrade.sh delete mode 100644 helm/templates/HomeAssistant/pv.yml delete mode 100644 helm/templates/HomeAssistant/pvc.yml delete mode 100644 helm/templates/HomeAssistant/service.yml delete mode 100644 helm/templates/HomeAssistant/statefulset.yml delete mode 100644 helm/templates/MQTT/deployment.yml delete mode 100644 helm/templates/MQTT/service.yml delete mode 100644 helm/values-homeserver.yml rename {PersonDetection => person-detection}/readme.md (100%) rename {PersonDetection => person-detection}/script.py (100%) rename {PersonDetection => person-detection}/test.jpg (100%) rename {RabbitMQ => rabbitmq}/Dockerfile (100%) rename {RabbitMQ => rabbitmq}/push.sh (100%) rename README.md => readme.md (100%) rename Server.md => server.md (100%) rename VPN.md => vpn.md (100%) diff --git a/Development.md b/Development.md deleted file mode 100644 index b4748bb..0000000 --- a/Development.md +++ /dev/null @@ -1,45 +0,0 @@ -# Development setup - -## Install kubectl on client machine - -See [installation tutorial here](https://kubernetes.io/docs/tasks/tools/install-kubectl-linux/) - -## Install helm on client machine - -See [installation tutorial here](https://helm.sh/docs/intro/install/) - -## Configure cluster with kubectl - -- Get cluster info with command `microk8s config` -- Add the cluster info to the kubectl config file on the client machine at `~/.kube/config` - -Example config file - -```bash -apiVersion: v1 -clusters: -- cluster: - certificate-authority-data: - ...... - server: https://63.250.54.81:16443 - name: homeserver -contexts: -- context: - cluster: homeserver - user: admin - name: homeserver -current-context: homeserver -kind: Config -preferences: {} -users: -- name: admin - user: - token: TnNDNURIV1I3RFdFMFora1NEaTdlNi9uNEgwR0pHRVRVajdPeFFrYWUvND0K -``` - -- In config file above, change context name -- To use this cluster with kubectl, enter `kubectl config use-context homeserver` - -## Configure cluster with helm - -- Run `helm --kube-context homeserver` diff --git a/helm/Chart.yaml b/helm/Chart.yaml deleted file mode 100644 index b43a021..0000000 --- a/helm/Chart.yaml +++ /dev/null @@ -1,2 +0,0 @@ -name: homeautomation -version: 0.0.2 diff --git a/helm/README.md b/helm/README.md deleted file mode 100644 index dc85335..0000000 --- a/helm/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# Helm - -This folder contains the helm template for my home automation setup. \ No newline at end of file diff --git a/helm/scripts/install.sh b/helm/scripts/install.sh deleted file mode 100755 index fabfaf5..0000000 --- a/helm/scripts/install.sh +++ /dev/null @@ -1 +0,0 @@ -helm --kube-context homeserver install -f ../values-homeserver.yml -n test test ../ \ No newline at end of file diff --git a/helm/scripts/registry-secret.sh b/helm/scripts/registry-secret.sh deleted file mode 100755 index 723ca6e..0000000 --- a/helm/scripts/registry-secret.sh +++ /dev/null @@ -1,6 +0,0 @@ -kubectl create secret docker-registry regcred ---docker-server=XXX ---docker-username=XXX ---docker-password=XXX ---docker-email=XXX --n XXX \ No newline at end of file diff --git a/helm/scripts/uninstall.sh b/helm/scripts/uninstall.sh deleted file mode 100755 index dd057d7..0000000 --- a/helm/scripts/uninstall.sh +++ /dev/null @@ -1 +0,0 @@ -helm --kube-context homeserver uninstall -n test test \ No newline at end of file diff --git a/helm/scripts/upgrade.sh b/helm/scripts/upgrade.sh deleted file mode 100755 index 6f6cfe5..0000000 --- a/helm/scripts/upgrade.sh +++ /dev/null @@ -1 +0,0 @@ -helm --kube-context homeserver upgrade -f ../values-homeserver.yml -n test test ../ \ No newline at end of file diff --git a/helm/templates/HomeAssistant/pv.yml b/helm/templates/HomeAssistant/pv.yml deleted file mode 100644 index 6b9430e..0000000 --- a/helm/templates/HomeAssistant/pv.yml +++ /dev/null @@ -1,21 +0,0 @@ -apiVersion: v1 -kind: PersistentVolume -metadata: - name: homeassistant-pv -spec: - capacity: - storage: 1Gi - volumeMode: Filesystem - accessModes: - - ReadWriteOnce - storageClassName: local-storage - local: - path: {{ .Values.homeassistant.config_folder }} - nodeAffinity: - required: - nodeSelectorTerms: - - matchExpressions: - - key: kubernetes.io/hostname - operator: In - values: - - {{ .Values.general.hostname }} \ No newline at end of file diff --git a/helm/templates/HomeAssistant/pvc.yml b/helm/templates/HomeAssistant/pvc.yml deleted file mode 100644 index d2bbb17..0000000 --- a/helm/templates/HomeAssistant/pvc.yml +++ /dev/null @@ -1,12 +0,0 @@ -apiVersion: v1 -kind: PersistentVolumeClaim -metadata: - name: homeassistant-pvc -spec: - accessModes: - - ReadWriteOnce - storageClassName: local-storage - resources: - requests: - storage: 1Gi - diff --git a/helm/templates/HomeAssistant/service.yml b/helm/templates/HomeAssistant/service.yml deleted file mode 100644 index 4833bff..0000000 --- a/helm/templates/HomeAssistant/service.yml +++ /dev/null @@ -1,14 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: homeassistant -spec: - type: NodePort - ports: - - port: 8123 - name: portal - targetPort: 8123 - nodePort: {{ .Values.homeassistant.portal_nodePort }} - protocol: TCP - selector: - app: homeassistant diff --git a/helm/templates/HomeAssistant/statefulset.yml b/helm/templates/HomeAssistant/statefulset.yml deleted file mode 100644 index f22e04d..0000000 --- a/helm/templates/HomeAssistant/statefulset.yml +++ /dev/null @@ -1,28 +0,0 @@ -apiVersion: apps/v1 -kind: StatefulSet -metadata: - name: homeassistant -spec: - serviceName: homeassistant - selector: - matchLabels: - app: homeassistant - replicas: 1 - template: - metadata: - labels: - app: homeassistant - spec: - containers: - - name: homeassistant - image: ghcr.io/home-assistant/home-assistant:stable - imagePullPolicy: "IfNotPresent" - ports: - - containerPort: 8123 - volumeMounts: - - name: homeassistant-config - mountPath: /config - volumes: - - name: homeassistant-config - persistentVolumeClaim: - claimName: homeassistant-pvc \ No newline at end of file diff --git a/helm/templates/MQTT/deployment.yml b/helm/templates/MQTT/deployment.yml deleted file mode 100644 index fecf5c0..0000000 --- a/helm/templates/MQTT/deployment.yml +++ /dev/null @@ -1,23 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: rabbitmq -spec: - selector: - matchLabels: - app: rabbitmq - replicas: 1 - template: - metadata: - labels: - app: rabbitmq - spec: - containers: - - name: rabbitmq - image: registry.willemserruys.com/rabbitmq - imagePullPolicy: "IfNotPresent" - ports: - - containerPort: 1883 - - containerPort: 15672 - imagePullSecrets: - - name: regcred \ No newline at end of file diff --git a/helm/templates/MQTT/service.yml b/helm/templates/MQTT/service.yml deleted file mode 100644 index a47880e..0000000 --- a/helm/templates/MQTT/service.yml +++ /dev/null @@ -1,19 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: rabbitmq -spec: - type: NodePort - ports: - - port: 1883 - name: mqtt - targetPort: 1883 - nodePort: {{ .Values.rabbitmq.mqtt_nodePort }} - protocol: TCP - - port: 15672 - name: portal - targetPort: 15672 - nodePort: {{ .Values.rabbitmq.portal_nodePort }} - protocol: TCP - selector: - app: rabbitmq diff --git a/helm/values-homeserver.yml b/helm/values-homeserver.yml deleted file mode 100644 index a8064ae..0000000 --- a/helm/values-homeserver.yml +++ /dev/null @@ -1,11 +0,0 @@ -general: -# This should be the name of your PC - hostname: willem-server - -rabbitmq: - mqtt_nodePort: 30001 - portal_nodePort: 30002 - -homeassistant: - portal_nodePort: 30003 - config_folder: /home/willem/homeassistant/config \ No newline at end of file diff --git a/PersonDetection/readme.md b/person-detection/readme.md similarity index 100% rename from PersonDetection/readme.md rename to person-detection/readme.md diff --git a/PersonDetection/script.py b/person-detection/script.py similarity index 100% rename from PersonDetection/script.py rename to person-detection/script.py diff --git a/PersonDetection/test.jpg b/person-detection/test.jpg similarity index 100% rename from PersonDetection/test.jpg rename to person-detection/test.jpg diff --git a/RabbitMQ/Dockerfile b/rabbitmq/Dockerfile similarity index 100% rename from RabbitMQ/Dockerfile rename to rabbitmq/Dockerfile diff --git a/RabbitMQ/push.sh b/rabbitmq/push.sh similarity index 100% rename from RabbitMQ/push.sh rename to rabbitmq/push.sh diff --git a/README.md b/readme.md similarity index 100% rename from README.md rename to readme.md diff --git a/Server.md b/server.md similarity index 100% rename from Server.md rename to server.md diff --git a/VPN.md b/vpn.md similarity index 100% rename from VPN.md rename to vpn.md