Make NATS API subjects configurable

This commit is contained in:
2025-12-17 06:08:09 +01:00
parent 0419fec810
commit d30c6ef3bf
2 changed files with 24 additions and 17 deletions

View File

@@ -22,6 +22,8 @@ type ProgramConfig struct {
// Addresses from which secured admin API endpoints can be reached, can be wildcard "*"
APIAllowedIPs []string `json:"apiAllowedIPs"`
APISubjects *NATSConfig `json:"apiSubjects"`
// Drop root permissions once .env was read and the port was taken.
User string `json:"user"`
Group string `json:"group"`
@@ -87,6 +89,12 @@ type ResampleConfig struct {
Trigger int `json:"trigger"`
}
type NATSConfig struct {
SubjectJobStart string `json:"subjectJobStart"`
SubjectJobStop string `json:"subjectJobStop"`
SubjectNodeState string `json:"subjectNodeState"`
}
type IntRange struct {
From int `json:"from"`
To int `json:"to"`