Skip to content

Commit

Permalink
Adds ingress path ratelimit example
Browse files Browse the repository at this point in the history
Fixes #1831

Signed-off-by: Alexander Yastrebov <[email protected]>
  • Loading branch information
AlexanderYastrebov committed Aug 19, 2021
1 parent 2059778 commit 7a3d1bb
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions docs/kubernetes/ingress-usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -736,6 +736,42 @@ spec:
servicePort: 80
```

#### Path ratelimit

To ratelimit a specific path use a second ingress definition like

```yaml
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: app-default
spec:
rules:
- host: app-default.example.org
http:
paths:
- backend:
serviceName: app-svc
servicePort: 80
---
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: app-login
annotations:
zalando.org/skipper-predicate: Path("/login")
zalando.org/skipper-filter: clusterClientRatelimit("login-ratelimit", 10, "1h")
spec:
rules:
- host: app-default.example.org
http:
paths:
- backend:
serviceName: app-svc
servicePort: 80
```
or use [RouteGroups](routegroups.md).

## Shadow Traffic

If you want to test a new replacement of a production service with
Expand Down

0 comments on commit 7a3d1bb

Please sign in to comment.