github.com/google/cloudprober@v0.11.3/rds/file/proto/config.proto (about) 1 // Configuration proto for Kubernetes provider. 2 // 3 // Example provider config: 4 // { 5 // pods {} 6 // } 7 // 8 // In probe config: 9 // probe { 10 // targets{ 11 // rds_targets { 12 // resource_path: "k8s://pods" 13 // filter { 14 // key: "namespace" 15 // value: "default" 16 // } 17 // filter { 18 // key: "name" 19 // value: "cloudprober.*" 20 // } 21 // } 22 // } 23 // } 24 syntax = "proto2"; 25 26 package cloudprober.rds.file; 27 28 import "github.com/google/cloudprober/rds/proto/rds.proto"; 29 30 option go_package = "github.com/google/cloudprober/rds/file/proto"; 31 32 // File provider config. 33 message ProviderConfig { 34 // File that contains resources in either textproto or json format. 35 // Example in textproto format: 36 // 37 // resource { 38 // name: "switch-xx-01" 39 // ip: "10.11.112.3" 40 // port: 8080 41 // labels { 42 // key: "device_type" 43 // value: "switch" 44 // } 45 // } 46 // resource { 47 // name: "switch-yy-01" 48 // ip: "10.16.110.12" 49 // port: 8080 50 // } 51 repeated string file_path = 1; 52 53 enum Format { 54 UNSPECIFIED = 0; // Determine format using file extension/ 55 TEXTPB = 1; // Text proto format (.textpb). 56 JSON = 2; // JSON proto format (.json). 57 } 58 optional Format format = 2; 59 60 // If specified, file will be re-read at the given interval. 61 optional int32 re_eval_sec = 3; 62 63 // Whenever possible, we reload a file only if it has been modified since the 64 // last load. If following option is set, mod time check is disabled. 65 // Note that mod-time check doesn't work for GCS. 66 optional bool disable_modified_time_check = 4; 67 } 68 69 message FileResources { 70 repeated .cloudprober.rds.Resource resource = 1; 71 }