From 36dcfbfe2dbb3cb52c65821da636f434058d8c05 Mon Sep 17 00:00:00 2001 From: Ludovic Fernandez Date: Wed, 18 Apr 2018 18:16:03 +0200 Subject: [PATCH] Add HTTP headers to healthcheck. --- Gopkg.lock | 6 +++--- Gopkg.toml | 2 +- provider/label/label.go | 5 ----- .../traefik-extra-service-fabric/servicefabric_tmpl.go | 7 +++++++ 4 files changed, 11 insertions(+), 9 deletions(-) diff --git a/Gopkg.lock b/Gopkg.lock index 7c251c154..4f0b5e723 100644 --- a/Gopkg.lock +++ b/Gopkg.lock @@ -263,8 +263,8 @@ [[projects]] name = "github.com/containous/traefik-extra-service-fabric" packages = ["."] - revision = "2889df8d4f84315e6e527588554ed0ce9d062305" - version = "v1.1.5" + revision = "08668650856571f3529bde394a36a5c9cf16a991" + version = "v1.2.0" [[projects]] name = "github.com/coreos/bbolt" @@ -1674,6 +1674,6 @@ [solve-meta] analyzer-name = "dep" analyzer-version = 1 - inputs-digest = "c7d91203842be1915ca08a31917a079489bff7ffc6f2e494330e9556b4730a06" + inputs-digest = "43f8acdb9c80004418ca3fd30c4c82f47589f96845fbaf2eaca5924b137eeed6" solver-name = "gps-cdcl" solver-version = 1 diff --git a/Gopkg.toml b/Gopkg.toml index dd68c13c1..c5a849bc2 100644 --- a/Gopkg.toml +++ b/Gopkg.toml @@ -66,7 +66,7 @@ [[constraint]] name = "github.com/containous/traefik-extra-service-fabric" - version = "1.1.5" + version = "1.2.0" [[constraint]] name = "github.com/coreos/go-systemd" diff --git a/provider/label/label.go b/provider/label/label.go index 71f9e1a64..7c664e120 100644 --- a/provider/label/label.go +++ b/provider/label/label.go @@ -27,11 +27,6 @@ const ( DefaultBackendMaxconnExtractorFunc = "request.host" DefaultBackendLoadbalancerStickinessCookieName = "" DefaultBackendHealthCheckPort = 0 - - // TODO need to be remove in extra-service-fabric - DefaultWeightInt = 1 // Deprecated - DefaultPassHostHeaderBool = true // Deprecated - DefaultFrontendPriorityInt = 0 // Deprecated ) var ( diff --git a/vendor/github.com/containous/traefik-extra-service-fabric/servicefabric_tmpl.go b/vendor/github.com/containous/traefik-extra-service-fabric/servicefabric_tmpl.go index 28b00d0d2..524a3289b 100644 --- a/vendor/github.com/containous/traefik-extra-service-fabric/servicefabric_tmpl.go +++ b/vendor/github.com/containous/traefik-extra-service-fabric/servicefabric_tmpl.go @@ -54,6 +54,13 @@ const tmpl = ` path = "{{ $healthCheck.Path }}" port = {{ $healthCheck.Port }} interval = "{{ $healthCheck.Interval }}" + hostname = "{{ $healthCheck.Hostname }}" + {{if $healthCheck.Headers }} + [backends."{{ $backendName }}".healthCheck.headers] + {{range $k, $v := $healthCheck.Headers }} + {{$k}} = "{{$v}}" + {{end}} + {{end}} {{end}} {{range $instance := $partition.Instances}}