Conversation
api/server/server.go
Outdated
There was a problem hiding this comment.
I'm not sure if the code above is ok because in daemon.ContainerRestart there was a default 10 seconds to container.Restart only if not job.EnvExists("t") but cli always set 10 seconds default from cli/restart. Maybe old api?
I just commented what I would use if there wasn't that old 10 default in daemon.ContainerRestart
There was a problem hiding this comment.
Hmmm, looks like it was 0 if t is not passed in querystring, because it is always exists in env, even if it is "". WDYT?
There was a problem hiding this comment.
10 was default only for CLI. For API it is 0 as I see :/
There was a problem hiding this comment.
I'd prefer if the default (10) was pushed down into ContainerRestart() and not set here at the API level - otherwise we run the risk of having different defaults based on who is calling ContainerRestart(). Can we have ContainerRestart() treat 0 as "no value specified" and then have it default to 10?
There was a problem hiding this comment.
@LK4D4 I was referring to this 10 before, I mean this t was never met
|
@runcom Need rebase |
Signed-off-by: Antonio Murdaca <[email protected]>
572dcf8 to
e41192a
Compare
|
@LK4D4 done |
|
LGTM |
1 similar comment
|
LGTM |
Signed-off-by: Antonio Murdaca [email protected]