--- /dev/null
+# ==================================================================================
+#
+# Copyright (c) 2022 Samsung Electronics Co., Ltd. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+# ==================================================================================
+
+#!/bin/bash
+
+IS_HELM3=$(helm version --short|grep -e "^v3")
+
+while [ -n "$1" ]; do # while loop starts
+
+ case "$1" in
+
+ -f) OVERRIDEYAML=$2
+ shift
+ ;;
+ -c) LIST_OF_COMPONENTS=$2
+ shift
+ ;;
+ -o) KERNEL_OPTIMIZATION=true
+ ;;
+ *) echo "Option $1 not recognized" ;; # In case you typed a different option other than a,b,c
+
+ esac
+
+ shift
+
+done
+
+if [ -z "$OVERRIDEYAML" ];then
+ echo "****************************************************************************************************************"
+ echo " ERROR "
+ echo "****************************************************************************************************************"
+ echo "AIMLFW deployment without deployment recipe is currently disabled. Please specify an recipe with the -f option."
+ echo "****************************************************************************************************************"
+ exit 1
+fi
+
+if [ -z $IS_HELM3 ]
+then
+ echo "****************************************************************************************************************"
+ echo " ERROR "
+ echo "****************************************************************************************************************"
+ echo "AIMLFW deployment expects helm 3 installed"
+ echo "****************************************************************************************************************"
+ exit 1
+else
+ HAS_COMMON_PACKAGE=$(helm search repo local/aimlfw-common | grep aimlfw-common)
+fi
+
+
+if [ -z "$HAS_COMMON_PACKAGE" ];then
+ echo "****************************************************************************************************************"
+ echo " ERROR "
+ echo "****************************************************************************************************************"
+ echo "Can't locate the aimlfw-common helm package in the local repo. Please make sure that it is properly installed."
+ echo "****************************************************************************************************************"
+ exit 1
+fi
+
+COMPONENTS="tm data-extraction kfadapter aiml-dashboard aiml-notebook"
+
+
+
+for component in $COMPONENTS; do
+ sudo helm dep up helm/$component
+ echo "Installing $component"
+ helm install $component helm/$component -f $OVERRIDEYAML
+done
--- /dev/null
+# ==================================================================================
+#
+# Copyright (c) 2022 Samsung Electronics Co., Ltd. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+# ==================================================================================
+
+#!/bin/bash
+
+echo "Installing servecm (Chart Manager) and common templates to helm3"
+
+helm plugin install https://github.com/jdolitsky/helm-servecm
+eval $(helm env |grep HELM_REPOSITORY_CACHE)
+echo ${HELM_REPOSITORY_CACHE}
+
+helm servecm --port=8879 --context-path=/charts --storage local --storage-local-rootdir $HELM_REPOSITORY_CACHE/local/ <<EOF &
+yes
+EOF
+
+CURL_CMD="curl --silent --output /dev/null http://127.0.0.1:8879/charts"
+`${CURL_CMD}`
+READY=$?
+while [ ${READY} != 0 ]; do
+ echo "servecm not yet running. sleeping for 2 seconds"
+ sleep 2
+ `${CURL_CMD}`
+ READY=$?
+done
+echo "servcm up and running"
+
+eval $(helm env |grep HELM_REPOSITORY_CACHE)
+echo ${HELM_REPOSITORY_CACHE}
+mkdir -p "${HELM_REPOSITORY_CACHE}/local/"
+
+export COMMON_CHART_VERSION=$(cat aimlfw-common/Common-Template/helm/aimlfw-common/Chart.yaml | grep version | awk '{print $2}')
+helm package -d /tmp aimlfw-common/Common-Template/helm/aimlfw-common
+cp /tmp/aimlfw-common-${COMMON_CHART_VERSION}.tgz "${HELM_REPOSITORY_CACHE}/local/"
+helm repo remove local
+helm repo add local http://127.0.0.1:8879/charts
+
+echo "checking that aimlfw-common templates were added"
+helm search repo local/aimlfw-common
--- /dev/null
+# ==================================================================================
+#
+# Copyright (c) 2022 Samsung Electronics Co., Ltd. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+# ==================================================================================
+
+helm repo add bitnami https://charts.bitnami.com/bitnami
+helm install tm-db bitnami/postgresql --namespace traininghost
+while [[ $(kubectl get pods tm-db-postgresql-0 -n traininghost -o 'jsonpath={..status.conditions[?(@.type=="Ready")].status}') != "True" ]]; do echo "waiting for training manager db pod" && sleep 1; done
+echo "Installed tm-db"
+helm install cassandra --set dbUser.user="cassandra" --namespace="traininghost" bitnami/cassandra
+while [[ $(kubectl get pods cassandra-0 -n traininghost -o 'jsonpath={..status.conditions[?(@.type=="Ready")].status}') != "True" ]]; do echo "waiting for cassandra manager db pod" && sleep 1; done
+echo "Installed cassandra-db"
--- /dev/null
+# ==================================================================================
+#
+# Copyright (c) 2022 Samsung Electronics Co., Ltd. All Rights Reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+# ==================================================================================
+
+# For reading secrets in Kubeflow-Pipeline and SDK
+
+kubectl create clusterrole secret_reader --verb get,list --resource secret
+kubectl create rolebinding secret_pipline_runner_rb -n traininghost --serviceaccount kubeflow:pipeline-runner --clusterrole secret_reader
+kubectl create rolebinding traininghost_default_secret_rb -n kubeflow --serviceaccount traininghost:default --clusterrole secret_reader
--- /dev/null
+#Checking whether the user is added in the docker group or not.
+if [[ $(groups | grep docker) ]]; then
+ echo "You are already added to the docker group!"
+else
+ sudo groupadd docker
+ sudo usermod -aG docker $USER
+ echo "Adding you to the docker group re-login is required."
+ echo "Exiting now try to login again."
+ exit
+fi
+
+tools/kubernetes/install_k8s.sh
+tools/nfs/configure_nfs_server.sh localhost
+tools/helm/install_helm.sh
+tools/nfs/install_nfs_subdir_external_provisioner.sh localhost
+
+sudo bin/install_common_templates_to_helm.sh
+tools/leofs/bin/install_leofs.sh
+tools/kubeflow/bin/install_kubeflow.sh
+kubectl create namespace traininghost
+
+bin/install_rolebindings.sh
+bin/install_databases.sh
+bin/install.sh -f RECIPE_EXAMPLE/example_recipe_oran_g_release.yaml