github.com/juju/juju@v0.0.0-20240430160146-1752b71fcf00/storage/kubernetes.go (about) 1 // Copyright 2018 Canonical Ltd. 2 // Licensed under the AGPLv3, see LICENCE file for details. 3 4 package storage 5 6 // KubernetesFilesystemParams is a fully specified set of parameters for filesystem creation, 7 // derived from one or more of user-specified storage constraints, a 8 // storage pool definition, and charm storage metadata. 9 type KubernetesFilesystemParams struct { 10 // StorageName is the name of the storage as specified in the charm. 11 StorageName string 12 13 // Size is the minimum size of the filesystem in MiB. 14 Size uint64 15 16 // The provider type for this filesystem. 17 Provider ProviderType 18 19 // Attributes is a set of provider-specific options for storage creation, 20 // as defined in a storage pool. 21 Attributes map[string]interface{} 22 23 // ResourceTags is a set of tags to set on the created filesystem, if the 24 // storage provider supports tags. 25 ResourceTags map[string]string 26 27 // Attachment identifies the mount point the filesystem should be 28 // mounted at. 29 Attachment *KubernetesFilesystemAttachmentParams 30 } 31 32 // KubernetesFilesystemAttachmentParams is a set of parameters for filesystem attachment 33 // or detachment. 34 type KubernetesFilesystemAttachmentParams struct { 35 AttachmentParams 36 37 // Path is the path at which the filesystem is to be mounted on the pod that 38 // this attachment corresponds to. 39 Path string 40 } 41 42 // FilesystemAttachmentInfo describes a filesystem attachment. 43 type KubernetesFilesystemInfo struct { 44 // MountPoint is the path the filesystem is mounted at. 45 MountPoint string 46 47 // ReadOnly is true if the filesystem is readonly. 48 ReadOnly bool 49 50 // FilesystemId is a unique provider id for the filesystem. 51 FilesystemId string 52 53 // Pool is the name of the storage pool used to 54 // allocate the filesystem. 55 Pool string 56 57 // Size is the size of the filesystem in MiB. 58 Size uint64 59 }