From cf9063e1f88b6c44a0daccf305008840b7fa92de Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?S=C3=B6ren=20Henning?= <soeren.henning@email.uni-kiel.de>
Date: Thu, 18 Mar 2021 14:01:56 +0100
Subject: [PATCH] Change location of Helm chart

---
 .gitignore                                      |  3 +++
 .../helm/{theodolite-chart => }/.helmignore     |  0
 .../helm/{theodolite-chart => }/Chart.yaml      |  0
 execution/helm/README.md                        | 17 ++++++-----------
 .../{theodolite-chart => }/build-package.sh     |  0
 .../{ => preconfigs}/one-broker-values.yaml     |  0
 .../{theodolite-chart => }/templates/NOTES.txt  |  0
 .../templates/_helpers.tpl                      |  0
 .../templates/cluster-role-binding.yaml         |  0
 .../templates/cluster-role.yaml                 |  0
 .../templates/dashboard-config-map.yaml         |  0
 .../templates/kafka-client.yaml                 |  0
 .../prometheus-datasource-config-map.yaml       |  0
 .../templates/prometheus.yaml                   |  0
 .../templates/service-account.yaml              |  0
 .../templates/service-monitor.yaml              |  0
 .../templates/tests/test-connection.yaml        |  0
 .../helm/{theodolite-chart => }/update-index.sh |  8 +++++---
 .../helm/{theodolite-chart => }/values.yaml     |  0
 19 files changed, 14 insertions(+), 14 deletions(-)
 rename execution/helm/{theodolite-chart => }/.helmignore (100%)
 rename execution/helm/{theodolite-chart => }/Chart.yaml (100%)
 rename execution/helm/{theodolite-chart => }/build-package.sh (100%)
 rename execution/helm/{ => preconfigs}/one-broker-values.yaml (100%)
 rename execution/helm/{theodolite-chart => }/templates/NOTES.txt (100%)
 rename execution/helm/{theodolite-chart => }/templates/_helpers.tpl (100%)
 rename execution/helm/{theodolite-chart => }/templates/cluster-role-binding.yaml (100%)
 rename execution/helm/{theodolite-chart => }/templates/cluster-role.yaml (100%)
 rename execution/helm/{theodolite-chart => }/templates/dashboard-config-map.yaml (100%)
 rename execution/helm/{theodolite-chart => }/templates/kafka-client.yaml (100%)
 rename execution/helm/{theodolite-chart => }/templates/prometheus-datasource-config-map.yaml (100%)
 rename execution/helm/{theodolite-chart => }/templates/prometheus.yaml (100%)
 rename execution/helm/{theodolite-chart => }/templates/service-account.yaml (100%)
 rename execution/helm/{theodolite-chart => }/templates/service-monitor.yaml (100%)
 rename execution/helm/{theodolite-chart => }/templates/tests/test-connection.yaml (100%)
 rename execution/helm/{theodolite-chart => }/update-index.sh (51%)
 rename execution/helm/{theodolite-chart => }/values.yaml (100%)

diff --git a/.gitignore b/.gitignore
index 71305e60a..e898f39a2 100644
--- a/.gitignore
+++ b/.gitignore
@@ -33,3 +33,6 @@ tmp/
 
 # Python cache files
 *.pyc
+
+# Helm
+Chart.lock
diff --git a/execution/helm/theodolite-chart/.helmignore b/execution/helm/.helmignore
similarity index 100%
rename from execution/helm/theodolite-chart/.helmignore
rename to execution/helm/.helmignore
diff --git a/execution/helm/theodolite-chart/Chart.yaml b/execution/helm/Chart.yaml
similarity index 100%
rename from execution/helm/theodolite-chart/Chart.yaml
rename to execution/helm/Chart.yaml
diff --git a/execution/helm/README.md b/execution/helm/README.md
index a522bf95f..4cacd06c8 100644
--- a/execution/helm/README.md
+++ b/execution/helm/README.md
@@ -2,19 +2,14 @@
 
 ## Installation
 
-Load all dependencies:
+Install the chart via:
 
 ```sh
-helm dependencies update ./theodolite-chart
+helm dependencies update .
+helm install my-confluent .
 ```
 
-Install the chart:
-
-```sh
-helm install my-confluent ./theodolite-chart
-```
-
-**Please note: Theodolite uses hard-coded URLs, to connect to Kafka and Zookeeper. For that reason, the name of this chart must be `my-confluent`.** We will change this behavior soon.
+**Please note: Theodolite currently uses hard-coded URLs, to connect to Kafka and Zookeeper. For that reason, the name of this chart must be `my-confluent`.** We will change this behavior soon.
 
 This chart installs requirements to execute benchmarks with Theodolite.
 
@@ -35,7 +30,7 @@ Test the installation:
 helm test <release-name>
 ```
 
-Our test files are located [here](./theodolite-chart/templates/../../theodolite-chart/templates/tests). Many subcharts have their own tests, these are also executed and are placed in the respective /templates folders. 
+Our test files are located [here](templates/../../theodolite-chart/templates/tests). Many subcharts have their own tests, these are also executed and are placed in the respective /templates folders. 
 
 Please note: If a test fails, Helm will stop testing.
 
@@ -46,7 +41,7 @@ It is possible that the tests are not running successfully at the moment. This i
 In development environments Kubernetes resources are often low. To reduce resource consumption, we provide an `one-broker-value.yaml` file. This file can be used with:
 
 ```sh
-helm install theodolite <path-to-chart> -f one-broker-values.yaml
+helm install theodolite . -f preconfigs/one-broker-values.yaml
 ```
 
 ## Development
diff --git a/execution/helm/theodolite-chart/build-package.sh b/execution/helm/build-package.sh
similarity index 100%
rename from execution/helm/theodolite-chart/build-package.sh
rename to execution/helm/build-package.sh
diff --git a/execution/helm/one-broker-values.yaml b/execution/helm/preconfigs/one-broker-values.yaml
similarity index 100%
rename from execution/helm/one-broker-values.yaml
rename to execution/helm/preconfigs/one-broker-values.yaml
diff --git a/execution/helm/theodolite-chart/templates/NOTES.txt b/execution/helm/templates/NOTES.txt
similarity index 100%
rename from execution/helm/theodolite-chart/templates/NOTES.txt
rename to execution/helm/templates/NOTES.txt
diff --git a/execution/helm/theodolite-chart/templates/_helpers.tpl b/execution/helm/templates/_helpers.tpl
similarity index 100%
rename from execution/helm/theodolite-chart/templates/_helpers.tpl
rename to execution/helm/templates/_helpers.tpl
diff --git a/execution/helm/theodolite-chart/templates/cluster-role-binding.yaml b/execution/helm/templates/cluster-role-binding.yaml
similarity index 100%
rename from execution/helm/theodolite-chart/templates/cluster-role-binding.yaml
rename to execution/helm/templates/cluster-role-binding.yaml
diff --git a/execution/helm/theodolite-chart/templates/cluster-role.yaml b/execution/helm/templates/cluster-role.yaml
similarity index 100%
rename from execution/helm/theodolite-chart/templates/cluster-role.yaml
rename to execution/helm/templates/cluster-role.yaml
diff --git a/execution/helm/theodolite-chart/templates/dashboard-config-map.yaml b/execution/helm/templates/dashboard-config-map.yaml
similarity index 100%
rename from execution/helm/theodolite-chart/templates/dashboard-config-map.yaml
rename to execution/helm/templates/dashboard-config-map.yaml
diff --git a/execution/helm/theodolite-chart/templates/kafka-client.yaml b/execution/helm/templates/kafka-client.yaml
similarity index 100%
rename from execution/helm/theodolite-chart/templates/kafka-client.yaml
rename to execution/helm/templates/kafka-client.yaml
diff --git a/execution/helm/theodolite-chart/templates/prometheus-datasource-config-map.yaml b/execution/helm/templates/prometheus-datasource-config-map.yaml
similarity index 100%
rename from execution/helm/theodolite-chart/templates/prometheus-datasource-config-map.yaml
rename to execution/helm/templates/prometheus-datasource-config-map.yaml
diff --git a/execution/helm/theodolite-chart/templates/prometheus.yaml b/execution/helm/templates/prometheus.yaml
similarity index 100%
rename from execution/helm/theodolite-chart/templates/prometheus.yaml
rename to execution/helm/templates/prometheus.yaml
diff --git a/execution/helm/theodolite-chart/templates/service-account.yaml b/execution/helm/templates/service-account.yaml
similarity index 100%
rename from execution/helm/theodolite-chart/templates/service-account.yaml
rename to execution/helm/templates/service-account.yaml
diff --git a/execution/helm/theodolite-chart/templates/service-monitor.yaml b/execution/helm/templates/service-monitor.yaml
similarity index 100%
rename from execution/helm/theodolite-chart/templates/service-monitor.yaml
rename to execution/helm/templates/service-monitor.yaml
diff --git a/execution/helm/theodolite-chart/templates/tests/test-connection.yaml b/execution/helm/templates/tests/test-connection.yaml
similarity index 100%
rename from execution/helm/theodolite-chart/templates/tests/test-connection.yaml
rename to execution/helm/templates/tests/test-connection.yaml
diff --git a/execution/helm/theodolite-chart/update-index.sh b/execution/helm/update-index.sh
similarity index 51%
rename from execution/helm/theodolite-chart/update-index.sh
rename to execution/helm/update-index.sh
index da7fb2150..286724dd8 100755
--- a/execution/helm/theodolite-chart/update-index.sh
+++ b/execution/helm/update-index.sh
@@ -1,7 +1,9 @@
 #!/usr/bin/env sh
 
-RELEASE_PATH="https://github.com/cau-se/theodolite/releases/download"
 RELEASE_NAME=$1 # Supposed to be equal to tag, e.g., v0.3.0
 
-helm repo index . --url $RELEASE_PATH/$RELEASE_NAME --merge ../../../docs/index.yaml && \
-  mv index.yaml ../../../docs/index.yaml
\ No newline at end of file
+RELEASE_PATH="https://github.com/cau-se/theodolite/releases/download"
+REPO_INDEX="../../docs/index.yaml"
+
+helm repo index . --url $RELEASE_PATH/$RELEASE_NAME --merge $REPO_INDEX && \
+  mv index.yaml $REPO_INDEX
\ No newline at end of file
diff --git a/execution/helm/theodolite-chart/values.yaml b/execution/helm/values.yaml
similarity index 100%
rename from execution/helm/theodolite-chart/values.yaml
rename to execution/helm/values.yaml
-- 
GitLab