-
Notifications
You must be signed in to change notification settings - Fork 200
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
feat(spc): add capability to specify allowed BD tags on SPC #1748
Conversation
This commit adds capability to specify allowed BD tags on SPC via annotations. The annotation key is `cstor.openebs.io/allowed-bd-tags` and allowed value is comma separated strings. For example "fast,slow" is a possible value and in this case SPC provisioner will reject BDs that have a BD tag (`openebs.io/block-device-tag`) present on it and the value is other than fast or slow. Signed-off-by: Ashutosh Kumar <ashutosh.kumar@mayadata.io>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good. given some nitpick comments.
Signed-off-by: Ashutosh Kumar <ashutosh.kumar@mayadata.io>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changes are good
@@ -809,3 +809,295 @@ func TestFilterNonReleasedDevices(t *testing.T) { | |||
}) | |||
} | |||
} | |||
|
|||
func TestBDTagFilter(t *testing.T) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice UT... I like the tag names:+1:
Signed-off-by: Ashutosh Kumar <ashutosh.kumar@mayadata.io>
…archive#1748) * feat(spc): add capability to specify allowed BD tags on SPC This commit adds the capability to specify allowed BD tags on SPC via annotations. The annotation key is `openebs.io/allowed-bd-tags` and the allowed value is comma separated strings. For example: "fast,slow" is a possible value and in this case SPC provisioner will reject BDs that have a BD tag (`openebs.io/block-device-tag`) present on it and the value is other than fast or slow. Signed-off-by: Ashutosh Kumar <ashutosh.kumar@mayadata.io>
* feat(spc): add capability to specify allowed BD tags on SPC This commit adds the capability to specify allowed BD tags on SPC via annotations. The annotation key is `openebs.io/allowed-bd-tags` and the allowed value is comma separated strings. For example: "fast,slow" is a possible value and in this case SPC provisioner will reject BDs that have a BD tag (`openebs.io/block-device-tag`) present on it and the value is other than fast or slow. Signed-off-by: Ashutosh Kumar <ashutosh.kumar@mayadata.io>
This commit adds the capability to specify allowed BD tags on SPC via
annotations.
The annotation key is
cstor.openebs.io/allowed-bd-tags
and the allowed valueis comma-separated strings.
For example "fast,slow" is a possible value, and in this case SPC provisioner
will reject BDs that have a BD tag (
openebs.io/block-device-tag
) present onit and the value is other than fast or slow.
Signed-off-by: Ashutosh Kumar ashutosh.kumar@mayadata.io