Skip to content

doc: add blobfuse mount with managed identity doc #1464

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 1 commit into from
Jul 12, 2024

Conversation

umagnus
Copy link
Contributor

@umagnus umagnus commented Jul 10, 2024

What type of PR is this?

/kind documentation

What this PR does / why we need it:

doc: add mount azure blob storage doc
referring to https://github.com/qxsch/Azure-Aks/tree/master/aks-blobfuse-mi

Which issue(s) this PR fixes:

Fixes #

Requirements:

Special notes for your reviewer:

Release note:

none

@k8s-ci-robot k8s-ci-robot added kind/documentation Categorizes issue or PR as related to documentation. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jul 10, 2024
@k8s-ci-robot
Copy link
Contributor

Hi @umagnus. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Jul 10, 2024
@k8s-ci-robot k8s-ci-robot requested review from andyzhangx and cvvz July 10, 2024 07:48
az identity list -g "$resourcegroup" --query "[?name == 'aks-fuseblob-mi-agentpool'].clientId" -o tsv
```

## Using a dedicated user-assigned managed indentity
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

option#2:

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

az storage blob upload \
--account-name myaksblob \
--container-name mycontainer \
--name test.htm \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's remove this application example, make it simple

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

---

apiVersion: v1
kind: Service
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's remove this example, make it simple

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done


1. Now you can use the persistent volume claim ``pv-blob2`` in another deployment.

# Security consideration
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's remove this , make it simple

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Copy link
Member

@andyzhangx andyzhangx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jul 10, 2024
Copy link
Member

@andyzhangx andyzhangx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mountstorage --> blobfuse-mi

and pls also add dynamic provisioning example


---

apiVersion: v1
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove service

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

volumeHandle: pv-blob1
volumeAttributes:
protocol: fuse
resourceGroup: aks-fuseblob-mi
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rename as blobfuse-mi

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

volumeHandle: pv-blob1
volumeAttributes:
protocol: fuse
resourceGroup: aks-fuseblob-mi
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

blobfuse-mi

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done


- Create a storage account container, e.g.
```bash
resourcegroup="aks-fuseblob-mi"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

blobfuse-mi

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

app: nginx-app1
spec:
containers:
- image: mcr.microsoft.com/oss/nginx/nginx:1.19.5
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use this example config:

image: mcr.microsoft.com/oss/nginx/nginx:1.17.3-alpine
command:
- "/bin/sh"
- "-c"
- while true; do echo $(date) >> /mnt/blob/outfile; sleep 1; done

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@umagnus
Copy link
Contributor Author

umagnus commented Jul 11, 2024

mountstorage --> blobfuse-mi

and pls also add dynamic provisioning example

added dynamic provisioning example

storageAccount: EXISTING_STORAGE_ACCOUNT_NAME # optional, if use existing storage account
containerName: EXISTING_CONTAINER_NAME # optional, if use existing container
AzureStorageAuthType: MSI
AzureStorageIdentityClientID: "92926dfd-e61b-4730-85ab-5be73b374e82"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use `xxx-xx ..' for this

@@ -0,0 +1,27 @@
apiVersion: v1
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rename as deploy/example/blobfuse-mi/pv-blobfuse-mi.yaml

apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: pvc-blob2
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't need this, just use existing pvc-blob-csi-static.yaml under example dir

apiVersion: v1
kind: PersistentVolume
metadata:
name: pv-blob2
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just use pv-blobfuse-csi, then you could reuse existing pvc-blob-csi-static.yaml

@andyzhangx andyzhangx changed the title doc: add mount azure blob storage doc doc: add blobfuse mount with managed identity doc Jul 11, 2024
storageAccount: EXISTING_STORAGE_ACCOUNT_NAME # optional, if use existing storage account
containerName: EXISTING_CONTAINER_NAME # optional, if use existing container
AzureStorageAuthType: MSI
AzureStorageIdentityClientID: "xxxxx-xxxx-xxx-xxx-xxxxxxx"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how is this AzureStorageIdentityClientID generated? I think you need to add get ClientID into Before you begin section?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add it

@k8s-ci-robot
Copy link
Contributor

@umagnus: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
pull-blob-csi-driver-e2e 9fd13fe link true /test pull-blob-csi-driver-e2e
pull-blob-csi-driver-e2e-proxy 9fd13fe link true /test pull-blob-csi-driver-e2e-proxy
pull-blob-csi-driver-external-e2e-nfs 9fd13fe link true /test pull-blob-csi-driver-external-e2e-nfs

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

@umagnus
Copy link
Contributor Author

umagnus commented Jul 12, 2024

/retest

Copy link
Member

@andyzhangx andyzhangx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 12, 2024
@andyzhangx andyzhangx merged commit b328703 into kubernetes-sigs:master Jul 12, 2024
18 of 22 checks passed
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: andyzhangx, umagnus

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/documentation Categorizes issue or PR as related to documentation. lgtm "Looks good to me", indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants