Skip to content

Commit

Permalink
feat(crypto): unlimit v2 volume encrption from validator.
Browse files Browse the repository at this point in the history
ref: longhorn/longhorn 7355

Signed-off-by: James Lu <james.lu@suse.com>
  • Loading branch information
mantissahz committed Jan 8, 2025
1 parent e11c082 commit c5880dc
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions webhook/resources/volume/validator.go
Original file line number Diff line number Diff line change
Expand Up @@ -167,8 +167,10 @@ func (v *volumeValidator) Create(request *admission.Request, newObj runtime.Obje

// TODO: remove this check when we support the following features for SPDK volumes
if types.IsDataEngineV2(volume.Spec.DataEngine) {
if volume.Spec.Encrypted {
return werror.NewInvalidError("encrypted volume is not supported for data engine v2", "")
// if volume.Spec.Encrypted {
// return werror.NewInvalidError("encrypted volume is not supported for data engine v2", "")
if volume.Spec.BackingImage != "" {
return werror.NewInvalidError("backing image is not supported for data engine v2", "")
}
if types.IsDataFromVolume(volume.Spec.DataSource) {
return werror.NewInvalidError("clone is not supported for data engine v2", "")
Expand Down

0 comments on commit c5880dc

Please sign in to comment.