forked from Kuadrant/testsuite
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request Kuadrant#553 from Kuadrant/local-perf
Add initial kube-burner config and readme for perf testing
- Loading branch information
Showing
15 changed files
with
496 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
--- | ||
kind: Secret | ||
apiVersion: v1 | ||
metadata: | ||
name: aws-credentials | ||
labels: | ||
app: scale-test | ||
stringData: | ||
AWS_ACCESS_KEY_ID: {{ .KUADRANT_AWS_ACCESS_KEY_ID }} | ||
AWS_REGION: {{ .KUADRANT_AWS_REGION }} | ||
AWS_SECRET_ACCESS_KEY: {{ .KUADRANT_AWS_SECRET_ACCESS_KEY }} | ||
type: kuadrant.io/aws |
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,106 @@ | ||
--- | ||
metricsEndpoints: | ||
- endpoint: {{ .PROMETHEUS_URL }} | ||
token: {{ .PROMETHEUS_TOKEN }} | ||
metrics: | ||
- ./metrics.yaml | ||
{{ if .OS_INDEXING }} | ||
indexer: | ||
type: opensearch | ||
esServers: ["{{ .ES_SERVER }}"] | ||
insecureSkipVerify: true | ||
defaultIndex: kube-burner | ||
{{ else }} | ||
indexer: | ||
type: local | ||
metricsDirectory: ./metrics | ||
{{ end }} | ||
global: | ||
gc: true | ||
jobs: | ||
- name: scale-test-preparations | ||
jobIterations: 1 | ||
qps: 1 | ||
burst: 1 | ||
namespacedIterations: true | ||
namespace: scale-test | ||
waitWhenFinished: true | ||
objects: | ||
- objectTemplate: ./httpbin-deployment.yaml | ||
kind: Deployment | ||
replicas: 1 | ||
waitOptions: | ||
forCondition: "Available" | ||
customStatusPath: ".conditions[].type" | ||
- objectTemplate: ./httpbin-service.yaml | ||
kind: Service | ||
replicas: 1 | ||
- objectTemplate: ./aws-credentials.yaml | ||
kind: Secret | ||
replicas: 1 | ||
inputVars: | ||
KUADRANT_AWS_ACCESS_KEY_ID: "{{ .KUADRANT_AWS_ACCESS_KEY_ID }}" | ||
KUADRANT_AWS_REGION: "{{ .KUADRANT_AWS_REGION }}" | ||
KUADRANT_AWS_SECRET_ACCESS_KEY: "{{ .KUADRANT_AWS_SECRET_ACCESS_KEY }}" | ||
- name: scale-test-main | ||
jobIterations: 1 | ||
qps: 1 | ||
burst: 1 | ||
namespacedIterations: true | ||
namespace: scale-test | ||
waitWhenFinished: true | ||
objects: | ||
- objectTemplate: ./gw.yaml | ||
replicas: 1 | ||
waitOptions: | ||
forCondition: Programmed | ||
customStatusPath: ".conditions[].type" | ||
inputVars: | ||
KUADRANT_ZONE_ROOT_DOMAIN: "{{ .KUADRANT_ZONE_ROOT_DOMAIN }}" | ||
- objectTemplate: ./gw-tls-policy.yaml | ||
replicas: 1 | ||
waitOptions: | ||
forCondition: Enforced | ||
customStatusPath: ".conditions[].type" | ||
- objectTemplate: ./gw-dns-policy.yaml | ||
replicas: 1 | ||
waitOptions: | ||
forCondition: Enforced | ||
customStatusPath: ".conditions[].type" | ||
- objectTemplate: ./gw-rlp.yaml | ||
replicas: 1 | ||
waitOptions: | ||
forCondition: Accepted | ||
customStatusPath: ".conditions[].type" | ||
- objectTemplate: ./gw-auth-policy.yaml | ||
replicas: 1 | ||
waitOptions: | ||
forCondition: Accepted | ||
customStatusPath: ".conditions[].type" | ||
- objectTemplate: ./httproute.yaml | ||
replicas: 1 | ||
waitOptions: | ||
forCondition: Accepted | ||
customStatusPath: ".conditions[].type" | ||
inputVars: | ||
KUADRANT_ZONE_ROOT_DOMAIN: "{{ .KUADRANT_ZONE_ROOT_DOMAIN }}" | ||
- objectTemplate: ./httproute-rlp.yaml | ||
replicas: 1 | ||
waitOptions: | ||
forCondition: Enforced | ||
customStatusPath: ".conditions[].type" | ||
- objectTemplate: ./httproute-auth-policy.yaml | ||
replicas: 1 | ||
waitOptions: | ||
forCondition: Enforced | ||
customStatusPath: ".conditions[].type" | ||
- name: scale-test-safe-dnspolicy-cleanup | ||
jobType: delete | ||
jobIterations: 1 | ||
namespacedIterations: true | ||
namespace: scale-test | ||
waitWhenFinished: true | ||
objects: | ||
- kind: DNSPolicy | ||
apiVersion: kuadrant.io/v1alpha1 | ||
labelSelector: {kube-burner-job: scale-test-main} |
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,27 @@ | ||
apiVersion: kuadrant.io/v1beta2 | ||
kind: AuthPolicy | ||
metadata: | ||
name: gw-auth-policy-{{.Iteration}} | ||
labels: | ||
app: scale-test | ||
spec: | ||
targetRef: | ||
group: gateway.networking.k8s.io | ||
kind: Gateway | ||
name: scale-test-{{.Iteration}} | ||
rules: | ||
authorization: | ||
deny-all: | ||
opa: | ||
rego: "allow = false" | ||
response: | ||
unauthorized: | ||
headers: | ||
"content-type": | ||
value: application/json | ||
body: | ||
value: | | ||
{ | ||
"error": "Forbidden", | ||
"message": "Access denied by default by the gateway operator. If you are the administrator of the service, create a specific auth policy for the route." | ||
} |
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: kuadrant.io/v1alpha1 | ||
kind: DNSPolicy | ||
metadata: | ||
name: gw-dns-policy-{{.Iteration}} | ||
labels: | ||
app: scale-test | ||
spec: | ||
targetRef: | ||
group: gateway.networking.k8s.io | ||
kind: Gateway | ||
name: scale-test-{{.Iteration}} | ||
providerRefs: | ||
- name: aws-credentials |
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,17 @@ | ||
apiVersion: kuadrant.io/v1beta3 | ||
kind: RateLimitPolicy | ||
metadata: | ||
name: gw-rlp-{{.Iteration}} | ||
labels: | ||
app: scale-test | ||
spec: | ||
targetRef: | ||
group: gateway.networking.k8s.io | ||
kind: Gateway | ||
name: scale-test-{{.Iteration}} | ||
limits: | ||
"global": | ||
rates: | ||
- limit: 5 | ||
duration: 10 | ||
unit: second |
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,15 @@ | ||
apiVersion: kuadrant.io/v1alpha1 | ||
kind: TLSPolicy | ||
metadata: | ||
name: gw-tls-policy-{{.Iteration}} | ||
labels: | ||
app: scale-test | ||
spec: | ||
targetRef: | ||
group: gateway.networking.k8s.io | ||
kind: Gateway | ||
name: scale-test-{{.Iteration}} | ||
issuerRef: | ||
group: cert-manager.io | ||
kind: ClusterIssuer | ||
name: selfsigned-issuer |
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,21 @@ | ||
apiVersion: gateway.networking.k8s.io/v1 | ||
kind: Gateway | ||
metadata: | ||
name: scale-test-{{.Iteration}} | ||
labels: | ||
app: scale-test | ||
spec: | ||
gatewayClassName: istio | ||
listeners: | ||
- allowedRoutes: | ||
namespaces: | ||
from: All | ||
hostname: "*.scale-test-{{.Iteration}}.{{ .KUADRANT_ZONE_ROOT_DOMAIN }}" | ||
name: api | ||
port: 443 | ||
protocol: HTTPS | ||
tls: | ||
mode: Terminate | ||
certificateRefs: | ||
- name: scale-test-{{.Iteration}} | ||
kind: Secret |
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,24 @@ | ||
--- | ||
kind: Deployment | ||
apiVersion: apps/v1 | ||
metadata: | ||
name: httpbin | ||
labels: | ||
app: scale-test | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
app: scale-test | ||
template: | ||
metadata: | ||
labels: | ||
app: scale-test | ||
spec: | ||
containers: | ||
- name: httpbin | ||
image: 'quay.io/trepel/httpbin:jsmadis' | ||
ports: | ||
- name: api | ||
containerPort: 8080 | ||
protocol: TCP |
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,15 @@ | ||
--- | ||
kind: Service | ||
apiVersion: v1 | ||
metadata: | ||
name: httpbin | ||
labels: | ||
app: scale-test | ||
spec: | ||
ports: | ||
- name: http | ||
protocol: TCP | ||
port: 8080 | ||
targetPort: api | ||
selector: | ||
app: scale-test |
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: kuadrant.io/v1beta2 | ||
kind: AuthPolicy | ||
metadata: | ||
name: httproute-auth-policy-{{.Iteration}} | ||
labels: | ||
app: scale-test | ||
spec: | ||
targetRef: | ||
group: gateway.networking.k8s.io | ||
kind: HTTPRoute | ||
name: scale-test-{{.Iteration}} | ||
rules: | ||
authorization: | ||
allow-all: | ||
opa: | ||
rego: "allow = true" |
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,17 @@ | ||
apiVersion: kuadrant.io/v1beta3 | ||
kind: RateLimitPolicy | ||
metadata: | ||
name: httproute-rlp-{{.Iteration}} | ||
labels: | ||
app: scale-test | ||
spec: | ||
targetRef: | ||
group: gateway.networking.k8s.io | ||
kind: HTTPRoute | ||
name: scale-test-{{.Iteration}} | ||
limits: | ||
"httproute-level": | ||
rates: | ||
- limit: 10 | ||
duration: 10 | ||
unit: second |
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,24 @@ | ||
apiVersion: gateway.networking.k8s.io/v1 | ||
kind: HTTPRoute | ||
metadata: | ||
name: scale-test-{{.Iteration}} | ||
labels: | ||
app: scale-test | ||
spec: | ||
parentRefs: | ||
- group: gateway.networking.k8s.io | ||
kind: Gateway | ||
name: scale-test-{{.Iteration}} | ||
hostnames: | ||
- "api-{{.Iteration}}.scale-test-{{.Iteration}}.{{ .KUADRANT_ZONE_ROOT_DOMAIN }}" | ||
rules: | ||
- backendRefs: | ||
- group: '' | ||
kind: Service | ||
name: httpbin | ||
port: 8080 | ||
weight: 1 | ||
matches: | ||
- path: | ||
type: PathPrefix | ||
value: / |
Oops, something went wrong.