fix(region): container ShmSizeMB validation (#20248)

This commit is contained in:
Zexi Li
2024-05-13 14:47:54 +08:00
committed by GitHub
parent d99c3fe990
commit ed891ce666
+1 -1
View File
@@ -160,7 +160,7 @@ func (m *SContainerManager) ValidateSpec(ctx context.Context, userCred mcclient.
return errors.Wrap(err, "validate lifecycle")
}
if spec.ShmSizeMB < 64 {
if spec.ShmSizeMB != 0 && spec.ShmSizeMB < 64 {
return httperrors.NewInputParameterError("/dev/shm size is small than 64MB")
}