kadalu / moana

Moana is a frontend for the Kadalu Storage / GlusterFS. Moana provides tools for setting up and managing the Kadalu Storage / Gluster pools.
GNU General Public License v3.0
18 stars 7 forks source link

Labels support #316

Open aravindavk opened 1 year ago

aravindavk commented 1 year ago

Region

This label is set for nodes. While creating the Storage pool, don't allow the creation if the export directories are from different regions.

Support setting this label while adding a node or as a separate command.

kadalu node add server1.example.com --region blr1
kadalu node region blr1

General label support:

Add label to any resource. Some of the labels are inherited or automatic(Ex: region label of Storage pool and volume is inherited from the nodes, pool type as label, FS type as label to the Storage unit).

kadalu label add <resource> <identifier> <label1>,<label2> ..
kadalu label add node server1.example.com os=arm64,lowRAM
kadalu label add pool pool1 fast,ssd
kadalu label add volume vol1 app1
kadalu label add storage-unit server1:/exports/s1 ssd

List all the labels of an resource

kadalu label list <resource> <identifier>
kadalu label list pool pool1

Remove labels

kadalu label remove <resource> <identifier> <label1>,<label2>..
kadalu label remove pool pool1 fast

Reset all the labels (Remove all labels)

kadalu label reset <resource> <identifier>
kadalu label reset pool pool1

These labels will be used in various places like: