Skip to content

Latest commit

 

History

History
31 lines (23 loc) · 877 Bytes

File metadata and controls

31 lines (23 loc) · 877 Bytes

NOTE: Use --id=fake [tenant id] if cortex multi-tenancy is disabled [See line 16 in cortex values file]. In our case cortex tenant id is org1 [See line 142 in the cortex values file].

Port forward to get access cortex rules endpoint

kubectl port-forward service/cortex-nginx --namespace cortex 8001:80
URL=http://localhost:8001

Load a set of rules to a designated cortex endpoint

cortextool rules load ./rules/kubernetes-apps.yaml --address=${URL} --id=fake
cortextool rules load ./rules/kubernetes-storage.yaml --address=${URL} --id=fake

List the rules currently in the cortex ruler

cortextool rules list --address=${URL} --id=fake

Print the rules currently in the cortex ruler.

cortextool rules print --address=${URL} --id=fake