Skip to content

Commit 1510fb1

Browse files
committed
chore: refine blobfuse proxy install
1 parent a853fa5 commit 1510fb1

File tree

1 file changed

+14
-9
lines changed

1 file changed

+14
-9
lines changed

deploy/install-driver.sh

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -33,18 +33,23 @@ if [ $ver != "master" ]; then
3333
repo="$repo/$ver"
3434
fi
3535

36-
if [[ "$#" -gt 1 ]]; then
37-
if [[ "$2" == *"local"* ]] && [[ "$2" == *"blobfuse-proxy"* ]]; then
38-
echo "set enable-blobfuse-proxy as true ..."
39-
kubectl apply -f ./deploy/blobfuse-proxy/blobfuse-proxy.yaml
40-
sed -i 's/enable-blobfuse-proxy=false/enable-blobfuse-proxy=true/g' $repo/csi-blob-node.yaml
41-
fi
42-
fi
43-
4436
echo "Installing Azure Blob Storage CSI driver, version: $ver ..."
4537
kubectl apply -f $repo/rbac-csi-blob-controller.yaml
4638
kubectl apply -f $repo/rbac-csi-blob-node.yaml
4739
kubectl apply -f $repo/csi-blob-driver.yaml
4840
kubectl apply -f $repo/csi-blob-controller.yaml
49-
kubectl apply -f $repo/csi-blob-node.yaml
41+
42+
if [[ "$#" -gt 1 ]]; then
43+
if [[ "$2" == *"blobfuse-proxy"* ]]; then
44+
echo "set enable-blobfuse-proxy as true ..."
45+
kubectl apply -f ./deploy/blobfuse-proxy/blobfuse-proxy.yaml
46+
if [[ "$2" == *"local"* ]]; then
47+
cat $repo/csi-blob-node.yaml | sed 's/enable-blobfuse-proxy=false/enable-blobfuse-proxy=true/g' | kubectl apply -f -
48+
else
49+
curl -s $repo/csi-blob-node.yaml | sed 's/enable-blobfuse-proxy=false/enable-blobfuse-proxy=true/g' | kubectl apply -f -
50+
fi
51+
else
52+
kubectl apply -f $repo/csi-blob-node.yaml
53+
fi
54+
fi
5055
echo 'Azure Blob Storage CSI driver installed successfully.'

0 commit comments

Comments
 (0)