Skip to content

Commit 33d74f3

Browse files
committed
fix
1 parent 7671e9e commit 33d74f3

File tree

2 files changed

+3
-40
lines changed

2 files changed

+3
-40
lines changed

deploy/example/mountstorage/README.md

Lines changed: 3 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -15,21 +15,15 @@ You can also use a different managed-identity for different persistent volumes (
1515

1616
- Run `az account set --subscription "mysubscription"` to select the right subscription
1717

18-
- Create a storage account container and upload file, e.g.
18+
- Create a storage account container, e.g.
1919
```bash
2020
resourcegroup="aks-fuseblob-mi"
2121
storageaccountname="myaksblob"
2222
az storage account create -g "$resourcegroup" -n "$storageaccountname" --access-tier Hot --sku Standard_LRS
2323
az storage container create -n mycontainer --account-name "$storageaccountname" --public-access off
24-
az storage blob upload \
25-
--account-name myaksblob \
26-
--container-name mycontainer \
27-
--name test.htm \
28-
--file test.htm \
29-
--auth-mode key --account-key "$(az storage account keys list --account-name "$storageaccountname" --query '[0].value' -o tsv)"
3024
```
3125

32-
## Using kubelet identity
26+
## option#1: grant kubelet identity access to storage account
3327

3428
1. Give kubelet identity access to storage account
3529
```bash
@@ -44,7 +38,7 @@ You can also use a different managed-identity for different persistent volumes (
4438
az identity list -g "$resourcegroup" --query "[?name == 'aks-fuseblob-mi-agentpool'].clientId" -o tsv
4539
```
4640

47-
## Using a dedicated user-assigned managed identity
41+
## option#2: grant a dedicated user-assigned managed identity access to storage account
4842
You can use a dedicated user-assigned managed identity to mount the storage.
4943

5044
1. Create user-assigned managed identity and give access to storage account
@@ -150,22 +144,6 @@ You can use a dedicated user-assigned managed identity to mount the storage.
150144
persistentVolumeClaim:
151145
claimName: pvc-blob1
152146
status: {}
153-
154-
---
155-
156-
apiVersion: v1
157-
kind: Service
158-
metadata:
159-
name: nginx-app1
160-
labels:
161-
run: nginx-app1
162-
spec:
163-
ports:
164-
- port: 80
165-
protocol: TCP
166-
selector:
167-
app: nginx-app1
168-
type: LoadBalancer
169147
```
170148

171149
1. Apply the yaml files
@@ -262,10 +240,3 @@ You can use a dedicated user-assigned managed identity to mount the storage.
262240
```
263241

264242
1. Now you can use the persistent volume claim ``pv-blob2`` in another deployment.
265-
266-
# Security consideration
267-
You should use at least 2 nodepools (a system and a user node pool) and assign the storage identities just to the user nodepool. Identity needs to be assigned where the pvs are mounted.
268-
You can use tains to protect the user assigned identity to schedule only authorized pods on the nodepool, that requires the pvs.
269-
270-
271-
[install-azure-cli]: https://docs.microsoft.com/en-us/cli/azure/install-azure-cli

deploy/example/mountstorage/test.htm

Lines changed: 0 additions & 8 deletions
This file was deleted.

0 commit comments

Comments
 (0)