Support start_period for healthcheck in Docker Compose

Signed-off-by: Li Yi <denverdino@gmail.com>
This commit is contained in:
Li Yi 2017-08-20 10:39:05 +08:00 committed by Li Yi
parent 21b5bbe411
commit 0abdad615f
5 changed files with 10 additions and 7 deletions

View File

@ -114,6 +114,7 @@ services:
interval: 10s
timeout: 1s
retries: 5
start_period: 15s
# Any valid image reference - repo, tag, id, sha
image: redis

View File

@ -760,6 +760,7 @@ func TestFullExample(t *testing.T) {
Interval: "10s",
Timeout: "1s",
Retries: uint64Ptr(5),
StartPeriod: "15s",
},
Hostname: "foo",
Image: "redis",

File diff suppressed because one or more lines are too long

View File

@ -324,7 +324,8 @@
{"type": "array", "items": {"type": "string"}}
]
},
"timeout": {"type": "string"}
"timeout": {"type": "string"},
"start_period": {"type": "string"}
}
},
"deployment": {

View File

@ -172,7 +172,7 @@ type HealthCheckConfig struct {
Timeout string
Interval string
Retries *uint64
StartPeriod string
StartPeriod string `mapstructure:"start_period"`
Disable bool
}