-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
21 changed files
with
293 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+347 KB
api-management/4-protect-api-infrastructure/images/api-portal-bundle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 13 additions & 0 deletions
13
api-management/4-protect-api-infrastructure/manifests/api-bundle-access.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
apiVersion: hub.traefik.io/v1alpha1 | ||
kind: APIAccess | ||
metadata: | ||
name: protect-api-infrastructure-apimanagement-external-bundle | ||
namespace: apps | ||
spec: | ||
groups: | ||
- external | ||
apiBundles: | ||
- name: protect-api-infrastructure-apimanagement-bundle | ||
apiPlan: | ||
name: plan-for-bundle | ||
weight: 1 # Higher weight to prioritize this plan over previous APIAccess resources |
9 changes: 9 additions & 0 deletions
9
api-management/4-protect-api-infrastructure/manifests/api-bundle.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
apiVersion: hub.traefik.io/v1alpha1 | ||
kind: APIBundle | ||
metadata: | ||
name: protect-api-infrastructure-apimanagement-bundle | ||
namespace: apps | ||
spec: | ||
apis: | ||
- name: protect-api-infrastructure-apimanagement-weather | ||
- name: protect-api-infrastructure-apimanagement-whoami |
14 changes: 14 additions & 0 deletions
14
api-management/4-protect-api-infrastructure/manifests/api-plan-for-bundle.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
apiVersion: hub.traefik.io/v1alpha1 | ||
kind: APIPlan | ||
metadata: | ||
name: plan-for-bundle | ||
namespace: apps | ||
spec: | ||
title: "Weather & whoami Bundle Plan" | ||
description: "Enforces rate limits and quotas for both the Weather and Whoami APIs" | ||
rateLimit: | ||
limit: 1 | ||
period: 1s | ||
quota: | ||
limit: 500 | ||
period: 24h |
6 changes: 6 additions & 0 deletions
6
api-management/4-protect-api-infrastructure/manifests/whoami-api.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
apiVersion: hub.traefik.io/v1alpha1 | ||
kind: API | ||
metadata: | ||
name: protect-api-infrastructure-apimanagement-whoami | ||
namespace: apps | ||
spec: {} |
11 changes: 11 additions & 0 deletions
11
api-management/4-protect-api-infrastructure/manifests/whoami-apiaccess.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
--- | ||
apiVersion: hub.traefik.io/v1alpha1 | ||
kind: APIAccess | ||
metadata: | ||
name: protect-api-infrastructure-apimanagement-whoami | ||
namespace: apps | ||
spec: | ||
groups: | ||
- external | ||
apis: | ||
- name: protect-api-infrastructure-apimanagement-whoami |
16 changes: 16 additions & 0 deletions
16
api-management/4-protect-api-infrastructure/manifests/whoami-ingressroute.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
apiVersion: traefik.io/v1alpha1 | ||
kind: IngressRoute | ||
metadata: | ||
name: protect-api-infrastructure-apimanagement-whoami | ||
namespace: apps | ||
annotations: | ||
hub.traefik.io/api: protect-api-infrastructure-apimanagement-whoami | ||
spec: | ||
entryPoints: | ||
- web | ||
routes: | ||
- match: Host(`api.protect-infrastructure.apimanagement.docker.localhost`) && PathPrefix(`/whoami`) | ||
kind: Rule | ||
services: | ||
- name: whoami | ||
port: 80 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# syntax=docker/dockerfile:1.10 | ||
# syntax=docker/dockerfile:1.11 | ||
|
||
# golang builder | ||
FROM golang:1.23 AS builder | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.