#!/bin/bash

if [ "$1" = "i" ]
then
	kubectl apply -f ./preparaKanboard/kb-namespace.yaml
	kubectl apply -f ./preparaKanboard/pv-local-mysql-kb.yaml
	kubectl apply -f ./preparaKanboard/pv-local-kanboard.yaml
	helm install kanboard kanboard-chart/
else
	helm uninstall kanboard 
	kubectl delete -f ./preparaKanboard/kb-namespace.yaml
	kubectl delete -f ./preparaKanboard/pv-local-mysql-kb.yaml
	kubectl delete -f ./preparaKanboard/pv-local-kanboard.yaml
fi
