feat: allow specifying a custom app label alias when shipping logs via vector

Closes #7354
This commit is contained in:
Jose Diaz-Gonzalez committed 2025-01-03 23:38:20 -05:00
1 parent 60eab73c17
commit 869f9a0346
7 files changed
+146 -16

No files matched your search

+10 -5
View File
@@ -10,18 +10,23 @@ import (
// MaxSize is the default max retention size for docker logs
const MaxSize = "10m"
// AppLabelAlias is the property key for the app label alias
const AppLabelAlias = "com.dokku.app-name"
var (
// DefaultProperties is a map of all valid logs properties with corresponding default property values
DefaultProperties = map[string]string{
"max-size": "",
"vector-sink": "",
"app-label-alias": AppLabelAlias,
"max-size": MaxSize,
"vector-sink": "",
}
// GlobalProperties is a map of all valid global logs properties
GlobalProperties = map[string]bool{
"max-size": true,
"vector-image": true,
"vector-sink": true,
"app-label-alias": true,
"max-size": true,
"vector-image": true,
"vector-sink": true,
}
)