Skip to content

Commit

Permalink
chore: add schema
Browse files Browse the repository at this point in the history
Signed-off-by: Mark Phelps <[email protected]>
  • Loading branch information
markphelps committed Apr 24, 2024
1 parent 2396bd4 commit 5a4230a
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 7 deletions.
24 changes: 17 additions & 7 deletions config/flipt.schema.cue
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import "strings"
log?: #log
meta?: #meta
server?: #server
metrics?: #metrics
tracing?: #tracing
ui?: #ui

Expand Down Expand Up @@ -81,7 +82,7 @@ import "strings"
jwt?: {
enabled?: bool | *false
validate_claims?: {
issuer?: string
issuer?: string
subject?: string
audiences?: [...string]
}
Expand Down Expand Up @@ -209,7 +210,7 @@ import "strings"
repository: string
bundles_directory?: string
authentication?: {
type: "aws-ecr" | *"static"
type: "aws-ecr" | *"static"
username: string
password: string
}
Expand Down Expand Up @@ -269,13 +270,22 @@ import "strings"
grpc_conn_max_age_grace?: =~#duration
}

#metrics: {
enabled?: bool | *true
exporter?: *"prometheus" | "otlp"

otlp?: {
endpoint?: string | *"localhost:4317"
}
}

#tracing: {
enabled?: bool | *false
exporter?: *"jaeger" | "zipkin" | "otlp"
samplingRatio?: float & >= 0 & <= 1 | *1
enabled?: bool | *false
exporter?: *"jaeger" | "zipkin" | "otlp"
samplingRatio?: float & >=0 & <=1 | *1
propagators?: [
..."tracecontext" | "baggage" | "b3" | "b3multi" | "jaeger" | "xray" | "ottrace" | "none"
] | *["tracecontext", "baggage"]
..."tracecontext" | "baggage" | "b3" | "b3multi" | "jaeger" | "xray" | "ottrace" | "none",
] | *["tracecontext", "baggage"]

jaeger?: {
enabled?: bool | *false
Expand Down
27 changes: 27 additions & 0 deletions config/flipt.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -928,6 +928,33 @@
"required": [],
"title": "Server"
},
"metrics": {
"type": "object",
"additionalProperties": false,
"properties": {
"enabled": {
"type": "boolean",
"default": true
},
"exporter": {
"type": "string",
"enum": ["prometheus", "otlp"],
"default": "prometheus"
},
"otlp": {
"type": "object",
"additionalProperties": false,
"properties": {
"endpoint": {
"type": "string",
"default": "localhost:4317"
}
},
"title": "OTLP"
}
},
"title": "Metrics"
},
"tracing": {
"type": "object",
"additionalProperties": false,
Expand Down

0 comments on commit 5a4230a

Please sign in to comment.