Skip to content

Make deploy scripts use absolute paths instead of relative paths #16

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions deploy/kubernetes/delete-driver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
set -o nounset
set -o errexit

kubectl delete -f node.yaml --ignore-not-found
kubectl delete -f controller.yaml --ignore-not-found
kubectl delete -f setup-cluster.yaml --ignore-not-found
readonly PKGDIR="${GOPATH}/src/github.com/kubernetes-sigs/gcp-compute-persistent-disk-csi-driver"
readonly KUBEDEPLOY="${PKGDIR}/deploy/kubernetes"

kubectl delete -f "${KUBEDEPLOY}/node.yaml" --ignore-not-found
kubectl delete -f "${KUBEDEPLOY}/controller.yaml" --ignore-not-found
kubectl delete -f "${KUBEDEPLOY}/setup-cluster.yaml" --ignore-not-found
kubectl delete secret cloud-sa --ignore-not-found
9 changes: 6 additions & 3 deletions deploy/kubernetes/deploy-driver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,13 @@
set -o nounset
set -o errexit

readonly PKGDIR="${GOPATH}/src/github.com/kubernetes-sigs/gcp-compute-persistent-disk-csi-driver"
readonly KUBEDEPLOY="${PKGDIR}/deploy/kubernetes"

if ! kubectl get secret cloud-sa;
then
kubectl create secret generic cloud-sa --from-file="${SA_FILE}"
fi
kubectl apply -f setup-cluster.yaml
kubectl apply -f node.yaml
kubectl apply -f controller.yaml
kubectl apply -f "${KUBEDEPLOY}/setup-cluster.yaml"
kubectl apply -f "${KUBEDEPLOY}/node.yaml"
kubectl apply -f "${KUBEDEPLOY}/controller.yaml"