As you might have guessed we eventually will be playing around with Kasten. So we need to turn on the CSI hostpath driver and snapshotting in Minikube.
We will first take a look at all of the addons available:
minikube addons list

Now we will enable the two ones that we need;
minikube addons enable csi-hostpath-driver
and then
minikube addons enable volumesnapshots

and

The CSI local hostpath dirver will allow us to dynamically allocate storage. We need to change the default storage class to the hostpath driver.
First we can check if it is installed:
kubectl get sc

First lets take off the default storage class status for standard, make sure that you are in bash (type bash)
kubectl patch storageclass standard -p '{"metadata": {"annotations":{"storageclass.kubernetes.io/is-default-class":"false"}}}'
and now make the csi-hostpath-sc the default
kubectl patch storageclass csi-hostpath-sc -p '{"metadata": {"annotations":{"storageclass.kubernetes.io/is-default-class":"true"}}}'

Now lets test this out to make sure we can grab storage with a small nginx setup:
Create the namespace
kubectl create ns nginx
Now copy and paste the following:
cat <<EOF | kubectl apply -f -
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
name: nginxpvcclaim
namespace: nginx
spec:
accessModes:
- ReadWriteMany
resources:
requests:
storage: 1Gi
---
kind: Pod
apiVersion: v1
metadata:
name: nginxwebsite
namespace: nginx
labels:
run: nginx
spec:
volumes:
- name: storage
persistentVolumeClaim:
claimName: nginxpvcclaim
containers:
- name: nginxwebsite
image: nginx
ports:
- containerPort: 80
name: "http-server"
volumeMounts:
- mountPath: "/usr/share/nginx/html"
name: storage
EOF
Wait until the pod is running:
kubectl get pods -n nginx

If it is running then it probably got the storage that it needed :)
We can check that with a
kubectl get pvc -n nginx

The pvc is in a bound state which means that it is good

That is it for today. We have storage that we can automatically allocate and we also have the snapshotter ready for some Kasten fun in the future!