Skip to content

Commit

Permalink
chore: new fixtures
Browse files Browse the repository at this point in the history
  • Loading branch information
adityathebe committed Oct 1, 2024
1 parent df57f20 commit 2b45366
Show file tree
Hide file tree
Showing 8 changed files with 107 additions and 0 deletions.
23 changes: 23 additions & 0 deletions fixtures/minimal/http_auth_from_config_map.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
apiVersion: canaries.flanksource.com/v1
kind: Canary
metadata:
name: http-basic-auth
spec:
schedule: "@every 1m"
http:
- name: "basic auth fail"
url: https://httpbin.demo.aws.flanksource.com/basic-auth/hello/world
responseCodes: [401]
- name: "basic auth pass"
url: https://httpbin.demo.aws.flanksource.com/basic-auth/hello/world
responseCodes: [200]
username:
valueFrom:
configMapKeyRef:
name: basic-auth
key: username
password:
valueFrom:
configMapKeyRef:
name: basic-auth
key: password
15 changes: 15 additions & 0 deletions fixtures/minimal/http_auth_from_helm_ref.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: canaries.flanksource.com/v1
kind: Canary
metadata:
name: http-from-helm
spec:
schedule: "@every 1m"
http:
- name: HTTP check
url: $(url)
env:
- name: url
valueFrom:
helmRef:
name: podinfo
key: .ingress.hosts[0].host
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ kind: Canary
metadata:
name: http-basic-auth
spec:
schedule: "@every 1m"
http:
- name: "basic auth fail"
url: https://httpbin.demo.aws.flanksource.com/basic-auth/hello/world
Expand Down
20 changes: 20 additions & 0 deletions fixtures/minimal/http_auth_from_service_account.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
apiVersion: canaries.flanksource.com/v1
kind: Canary
metadata:
name: http-basic-auth-service-account
spec:
schedule: "@every 1m"
http:
- name: vault-example-sre
description: "HashiCorp Vault functionality check."
url: https://vault.example/v1/auth/kubernetes/login
env:
- name: TOKEN
valueFrom:
serviceAccount: default-account
templateBody: true
body: |
{
"jwt": "$(TOKEN)",
"role": "example-role"
}
11 changes: 11 additions & 0 deletions fixtures/minimal/http_simple.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: canaries.flanksource.com/v1
kind: Canary
metadata:
name: http-check
spec:
schedule: "@every 30s"
http:
- name: basic-check
url: https://httpbin.demo.aws.flanksource.com/status/200
- name: failing-check
url: https://httpbin.demo.aws.flanksource.com/status/500
11 changes: 11 additions & 0 deletions fixtures/minimal/http_tls_check_pass.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: canaries.flanksource.com/v1
kind: Canary
metadata:
name: http-tls-duration
spec:
schedule: "@every 5m"
http:
- name: http pass response 200 status code
endpoint: https://httpbin.demo.aws.flanksource.com/status/200
test:
expr: "code in [200,201,301] and sslAge > Duration('7d')"
15 changes: 15 additions & 0 deletions fixtures/minimal/http_tls_config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: canaries.flanksource.com/v1
kind: Canary
metadata:
name: http-check
spec:
schedule: "@every 30s"
http:
- name: http pass response 200 status code
url: https://httpbin.demo.aws.flanksource.com/status/200
tlsConfig:
ca:
valueFrom:
secretKeyRef:
name: ca-cert
key: ca.pem
11 changes: 11 additions & 0 deletions fixtures/minimal/http_trace_pass.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: canaries.flanksource.com/v1
kind: Canary
metadata:
name: http-check
annotations:
trace: "true"
spec:
schedule: "@every 30s"
http:
- name: headers check
url: https://httpbin.demo.aws.flanksource.com/headers

0 comments on commit 2b45366

Please sign in to comment.