In this example, we will run a HTTP Server test to monitor Cisco DevNet homepage.
You can define a HTTP Server CR below based on HTTP Server CRD:
CR: config/samples/cr/devnet_v1alpha1_httpservertest.yaml
apiVersion: thousandeyes.devnet.cisco.com/v1alpha1
kind: HTTPServerTest
metadata:
# the test name
name: httpserver-devnet-homepage
spec:
url: https://developer.cisco.com/
interval: 1800
agents:
- agentName: Tokyo, Japan (Trial)
- agentName: Singapore (Trial) - IPv6
alertRules:
- ruleName: Default HTTP Alert Rule
Field | Test Creation | Test Update | Data Type | Default Values (used for samples) | Notes |
---|---|---|---|---|---|
url | Required | n/a | string | target for the test | |
interval | Required | Optional | integer | 3600 | value in seconds. Accpeted Values:[120, 300, 600, 900, 1800, 3600] |
agents | Required | Optional | array of agentName | ||
agentName | Required | Optional | string | Tokyo, Japan (Trial), Singapore (Trial) - IPv6 | cloud agent name |
alertRules | Optional | Optional | array of ruleName | applicable defaults will be used. | if this field is not specified, The default alert rules will be used. |
ruleName | Optional | Optional | string | alert rule name |
For more details, please refer to HTTP Server in ThousandEyes Test Metadata.
Run the commands respectively, check the test on ThoudandEyes dashboard.
-
Create a HTTP Server test
kubectl apply -f config/samples/cr/devnet_v1alpha1_httpservertest.yaml
The test will be created on dashboard.
-
Update settings of this test
Modify fields in spec in devnet_v1alpha1_httpservertest.yaml and redeploy.
kubectl apply -f config/samples/cr/devnet_v1alpha1_httpservertest.yaml
You will find the settings have been updated.
-
Delete this test
kubectl delete -f config/samples/cr/devnet_v1alpha1_httpservertest.yaml
The test will be removed from ThousandEyes dashboard.