From 2d27524461e12e4c23d32e2d0f96a59add9863d4 Mon Sep 17 00:00:00 2001 From: Tim Gross Date: Wed, 11 May 2016 10:28:30 -0400 Subject: [PATCH 1/2] Remove stopTimeout from configMap before checking unknown keys --- config/config.go | 1 + core/app_test.go | 1 + 2 files changed, 2 insertions(+) diff --git a/config/config.go b/config/config.go index 8fe06cb6..e1e533a3 100644 --- a/config/config.go +++ b/config/config.go @@ -349,6 +349,7 @@ func decodeConfig(configMap map[string]interface{}, result *rawConfig) error { delete(configMap, "preStart") delete(configMap, "preStop") delete(configMap, "postStop") + delete(configMap, "stopTimeout") delete(configMap, "services") delete(configMap, "backends") delete(configMap, "tasks") diff --git a/core/app_test.go b/core/app_test.go index 2c5b2bb1..c39ee69f 100644 --- a/core/app_test.go +++ b/core/app_test.go @@ -16,6 +16,7 @@ var testJSON = `{ "preStart": "/bin/to/preStart.sh arg1 arg2", "preStop": ["/bin/to/preStop.sh","arg1","arg2"], "postStop": ["/bin/to/postStop.sh"], + "stopTimeout": 5, "services": [ { "name": "serviceA", From 5d716d3f825de0763e25cc431d63b9344140de4a Mon Sep 17 00:00:00 2001 From: Tim Gross Date: Wed, 11 May 2016 11:23:07 -0400 Subject: [PATCH 2/2] Update consul-template in test fixture to 0.14.0 --- integration_tests/fixtures/nginx/Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/integration_tests/fixtures/nginx/Dockerfile b/integration_tests/fixtures/nginx/Dockerfile index 053b3a03..5438dd25 100644 --- a/integration_tests/fixtures/nginx/Dockerfile +++ b/integration_tests/fixtures/nginx/Dockerfile @@ -9,8 +9,8 @@ RUN apk update && apk add \ && rm -rf /var/cache/apk/* # we use consul-template to re-write our Nginx virtualhost config -RUN curl -Lo /tmp/consul_template_0.11.0_linux_amd64.zip https://github.com/hashicorp/consul-template/releases/download/v0.11.0/consul_template_0.11.0_linux_amd64.zip && \ - unzip /tmp/consul_template_0.11.0_linux_amd64.zip && \ +RUN curl -Lo /tmp/consul_template_0.14.0_linux_amd64.zip https://releases.hashicorp.com/consul-template/0.14.0/consul-template_0.14.0_linux_amd64.zip && \ + unzip /tmp/consul_template_0.14.0_linux_amd64.zip && \ mv consul-template /bin # Add confd to re-write our Nginx config from etcd