Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
小 白蛋
Nomad
Commits
6b74643a
Unverified
Commit
6b74643a
authored
7 years ago
by
Thomas Bartelmess
Browse files
Options
Download
Email Patches
Plain Diff
Fixed error messges for MeetsMinResources
parent
fdafc294
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
nomad/structs/structs.go
+2
-2
nomad/structs/structs.go
with
2 additions
and
2 deletions
+2
-2
nomad/structs/structs.go
+
2
-
2
View file @
6b74643a
...
...
@@ -1293,10 +1293,10 @@ func (r *Resources) MeetsMinResources() error {
mErr
.
Errors
=
append
(
mErr
.
Errors
,
fmt
.
Errorf
(
"minimum CPU value is %d; got %d"
,
minResources
.
CPU
,
r
.
CPU
))
}
if
r
.
MemoryMB
<
minResources
.
MemoryMB
{
mErr
.
Errors
=
append
(
mErr
.
Errors
,
fmt
.
Errorf
(
"minimum MemoryMB value is %d; got %d"
,
minResources
.
CPU
,
r
.
MemoryMB
))
mErr
.
Errors
=
append
(
mErr
.
Errors
,
fmt
.
Errorf
(
"minimum MemoryMB value is %d; got %d"
,
minResources
.
MemoryMB
,
r
.
MemoryMB
))
}
if
r
.
IOPS
<
minResources
.
IOPS
{
mErr
.
Errors
=
append
(
mErr
.
Errors
,
fmt
.
Errorf
(
"minimum IOPS value is %d; got %d"
,
minResources
.
CPU
,
r
.
IOPS
))
mErr
.
Errors
=
append
(
mErr
.
Errors
,
fmt
.
Errorf
(
"minimum IOPS value is %d; got %d"
,
minResources
.
IOPS
,
r
.
IOPS
))
}
for
i
,
n
:=
range
r
.
Networks
{
if
err
:=
n
.
MeetsMinResources
();
err
!=
nil
{
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment