Skip to content

Commit

Permalink
fix: cookie doc.
Browse files Browse the repository at this point in the history
  • Loading branch information
ldez authored and traefiker committed Apr 29, 2020
1 parent e5c6b0d commit 02cddd9
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 11 deletions.
Expand Up @@ -147,7 +147,7 @@
- "traefik.http.services.service01.loadbalancer.healthcheck.followredirects=true"
- "traefik.http.services.service01.loadbalancer.passhostheader=true"
- "traefik.http.services.service01.loadbalancer.responseforwarding.flushinterval=foobar"
- "traefik.http.services.service01.loadbalancer.sticky=true"
- "traefik.http.services.service01.loadbalancer.sticky.cookie=true"
- "traefik.http.services.service01.loadbalancer.sticky.cookie.httponly=true"
- "traefik.http.services.service01.loadbalancer.sticky.cookie.name=foobar"
- "traefik.http.services.service01.loadbalancer.sticky.cookie.secure=true"
Expand Down
Expand Up @@ -145,6 +145,7 @@
"traefik.http.services.service01.loadbalancer.healthcheck.followredirects": "true",
"traefik.http.services.service01.loadbalancer.passhostheader": "true",
"traefik.http.services.service01.loadbalancer.responseforwarding.flushinterval": "foobar",
"traefik.http.services.service01.loadbalancer.sticky.cookie": "true",
"traefik.http.services.service01.loadbalancer.sticky.cookie.httponly": "true",
"traefik.http.services.service01.loadbalancer.sticky.cookie.name": "foobar",
"traefik.http.services.service01.loadbalancer.sticky.cookie.secure": "true",
Expand Down
4 changes: 2 additions & 2 deletions docs/content/routing/providers/docker.md
Expand Up @@ -334,12 +334,12 @@ you'd add the label `traefik.http.services.<name-of-your-choice>.loadbalancer.pa
- "traefik.http.services.myservice.loadbalancer.healthcheck.followredirects=true"
```

??? info "`traefik.http.services.<service_name>.loadbalancer.sticky`"
??? info "`traefik.http.services.<service_name>.loadbalancer.sticky.cookie`"

See [sticky sessions](../services/index.md#sticky-sessions) for more information.

```yaml
- "traefik.http.services.myservice.loadbalancer.sticky=true"
- "traefik.http.services.myservice.loadbalancer.sticky.cookie=true"
```

??? info "`traefik.http.services.<service_name>.loadbalancer.sticky.cookie.httponly`"
Expand Down
4 changes: 2 additions & 2 deletions docs/content/routing/providers/kv.md
Expand Up @@ -106,8 +106,8 @@ A Story of key & values

See [servers](../services/index.md#servers) for more information.

| Key (Path) | Value -------------------------- |
|-----------------------------------------------------------------|---------------------------------------------------------|
| Key (Path) | Value |
|-----------------------------------------------------------------|-----------------------------------------|
| `traefik/http/services/myservice/loadbalancer/servers/0/url` | `http://<ip-server-1>:<port-server-1>/` |

??? info "`traefik/http/services/<service_name>/loadbalancer/passhostheader`"
Expand Down
4 changes: 2 additions & 2 deletions docs/content/routing/providers/marathon.md
Expand Up @@ -232,12 +232,12 @@ For example, to change the passHostHeader behavior, you'd add the label `"traefi
"traefik.http.services.myservice.loadbalancer.healthcheck.followredirects": "true"
```

??? info "`traefik.http.services.<service_name>.loadbalancer.sticky`"
??? info "`traefik.http.services.<service_name>.loadbalancer.sticky.cookie`"

See [sticky sessions](../services/index.md#sticky-sessions) for more information.

```json
"traefik.http.services.myservice.loadbalancer.sticky": "true"
"traefik.http.services.myservice.loadbalancer.sticky.cookie": "true"
```

??? info "`traefik.http.services.<service_name>.loadbalancer.sticky.cookie.httponly`"
Expand Down
4 changes: 2 additions & 2 deletions docs/content/routing/providers/rancher.md
Expand Up @@ -238,12 +238,12 @@ you'd add the label `traefik.http.services.{name-of-your-choice}.loadbalancer.pa
- "traefik.http.services.myservice.loadbalancer.healthcheck.followredirects=true"
```

??? info "`traefik.http.services.<service_name>.loadbalancer.sticky`"
??? info "`traefik.http.services.<service_name>.loadbalancer.sticky.cookie`"

See [sticky sessions](../services/index.md#sticky-sessions) for more information.

```yaml
- "traefik.http.services.myservice.loadbalancer.sticky=true"
- "traefik.http.services.myservice.loadbalancer.sticky.cookie=true"
```

??? info "`traefik.http.services.<service_name>.loadbalancer.sticky.cookie.httponly`"
Expand Down
2 changes: 1 addition & 1 deletion pkg/config/dynamic/http_config.go
Expand Up @@ -103,7 +103,7 @@ func (w *WRRService) SetDefaults() {

// Sticky holds the sticky configuration.
type Sticky struct {
Cookie *Cookie `json:"cookie,omitempty" toml:"cookie,omitempty" yaml:"cookie,omitempty"`
Cookie *Cookie `json:"cookie,omitempty" toml:"cookie,omitempty" yaml:"cookie,omitempty" label:"allowEmpty"`
}

// +k8s:deepcopy-gen=true
Expand Down
Expand Up @@ -9,7 +9,7 @@ metadata:
traefik.ingress.kubernetes.io/foo: bar
traefik.ingress.kubernetes.io/service.serversscheme: protocol
traefik.ingress.kubernetes.io/service.passhostheader: "true"
traefik.ingress.kubernetes.io/service.sticky: "true"
traefik.ingress.kubernetes.io/service.sticky.cookie: "true"
traefik.ingress.kubernetes.io/service.sticky.cookie.httponly: "true"
traefik.ingress.kubernetes.io/service.sticky.cookie.name: foobar
traefik.ingress.kubernetes.io/service.sticky.cookie.secure: "true"
Expand Down

0 comments on commit 02cddd9

Please sign in to comment.