Signed-off-by: gunadhya <6939749+gunadhya@users.noreply.github.com>
(cherry picked from commit 64465f3b5fbde37ee165893248d80b24e51102aa)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
| ... | ... |
@@ -461,7 +461,7 @@ func verifyPlatformContainerResources(resources *containertypes.Resources, sysIn |
| 461 | 461 |
resources.MemoryReservation = 0 |
| 462 | 462 |
} |
| 463 | 463 |
if resources.MemoryReservation > 0 && resources.MemoryReservation < linuxMinMemory {
|
| 464 |
- return warnings, fmt.Errorf("Minimum memory reservation allowed is 4MB")
|
|
| 464 |
+ return warnings, fmt.Errorf("Minimum memory reservation allowed is 6MB")
|
|
| 465 | 465 |
} |
| 466 | 466 |
if resources.Memory > 0 && resources.MemoryReservation > 0 && resources.Memory < resources.MemoryReservation {
|
| 467 | 467 |
return warnings, fmt.Errorf("Minimum memory limit can not be less than memory reservation limit, see usage")
|
| ... | ... |
@@ -697,7 +697,7 @@ func (s *DockerSuite) TestRunWithMemoryReservationInvalid(c *testing.T) {
|
| 697 | 697 |
assert.Assert(c, strings.Contains(strings.TrimSpace(out), expected), "run container should fail with invalid memory reservation") |
| 698 | 698 |
out, _, err = dockerCmdWithError("run", "--memory-reservation", "1k", "busybox", "true")
|
| 699 | 699 |
assert.ErrorContains(c, err, "") |
| 700 |
- expected = "Minimum memory reservation allowed is 4MB" |
|
| 700 |
+ expected = "Minimum memory reservation allowed is 6MB" |
|
| 701 | 701 |
assert.Assert(c, strings.Contains(strings.TrimSpace(out), expected), "run container should fail with invalid memory reservation") |
| 702 | 702 |
} |
| 703 | 703 |
|