mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 11:21:47 +00:00
Merge pull request #60265 from mlmhl/storageclass_describe
Automatic merge from submit-queue (batch tested with PRs 57672, 60299, 59757, 60283, 60265). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Add description of MountOptions to StorageClass describe printer **What this PR does / why we need it**: Print `StorageClass.MountOptions` for `kubectl describe` command. **Release note**: ```release-note NONE ```
This commit is contained in:
commit
2f09876c44
@ -3285,6 +3285,14 @@ func describeStorageClass(sc *storage.StorageClass, events *api.EventList) (stri
|
||||
w.Write(LEVEL_0, "Provisioner:\t%s\n", sc.Provisioner)
|
||||
w.Write(LEVEL_0, "Parameters:\t%s\n", labels.FormatLabels(sc.Parameters))
|
||||
w.Write(LEVEL_0, "AllowVolumeExpansion:\t%s\n", printBoolPtr(sc.AllowVolumeExpansion))
|
||||
if len(sc.MountOptions) == 0 {
|
||||
w.Write(LEVEL_0, "MountOptions:\t<none>\n")
|
||||
} else {
|
||||
w.Write(LEVEL_0, "MountOptions:\n")
|
||||
for _, option := range sc.MountOptions {
|
||||
w.Write(LEVEL_1, "%s\n", option)
|
||||
}
|
||||
}
|
||||
if sc.ReclaimPolicy != nil {
|
||||
w.Write(LEVEL_0, "ReclaimPolicy:\t%s\n", *sc.ReclaimPolicy)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user