Skip to content
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

Add volume commands #645

Merged
merged 1 commit into from
Sep 27, 2022
Merged

Conversation

balamurugana
Copy link
Member

@balamurugana balamurugana commented Sep 20, 2022

No description provided.

@balamurugana balamurugana marked this pull request as draft September 20, 2022 16:15
@balamurugana balamurugana force-pushed the add-volume-commands branch 4 times, most recently from 756bae2 to 10fa6be Compare September 21, 2022 09:07
@balamurugana balamurugana marked this pull request as ready for review September 21, 2022 13:46
Signed-off-by: Bala.FA <bala@minio.io>
Comment on lines +80 to +98
func getDriveSelectors() ([]types.LabelValue, error) {
var values []string
for i := range driveArgs {
if utils.TrimDevPrefix(driveArgs[i]) == "" {
return nil, fmt.Errorf("empty device name %v", driveArgs[i])
}
values = append(values, utils.TrimDevPrefix(driveArgs[i]))
}
return getSelectorValues(values)
}

func getNodeSelectors() ([]types.LabelValue, error) {
for i := range nodeArgs {
if utils.TrimDevPrefix(nodeArgs[i]) == "" {
return nil, fmt.Errorf("empty node name %v", nodeArgs[i])
}
}
return getSelectorValues(nodeArgs)
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

can these functions move to common utils.go file as it can be used for drive listing as well?

@Praveenrajmani Praveenrajmani merged commit d6e1faa into minio:devel Sep 27, 2022
@balamurugana balamurugana deleted the add-volume-commands branch September 27, 2022 06:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants