-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathmodel.go
More file actions
31 lines (28 loc) · 734 Bytes
/
Copy pathmodel.go
File metadata and controls
31 lines (28 loc) · 734 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package main
import (
"time"
)
type Config struct {
Address string `yaml:"address"`
Port int `yaml:"port"`
Users []User `yaml:"users"`
Encoding string `yaml:"encoding"`
Nats struct {
Url string `yaml:"url"`
CredsFile string `yaml:"creds-file"`
Subject string `yaml:"subject"`
RootCa string `yaml:"root-ca"`
Jetstream bool `yaml:"jetstream"`
} `yaml:"nats"`
Stats struct {
Subject string `yaml:"subject"`
Interval time.Duration `yaml:"interval"`
} `yaml:"stats"`
}
type User struct {
User string `yaml:"user"`
AuthAlg string `yaml:"auth-alg"`
AuthPasswd string `yaml:"auth-passwd"`
PrivAlg string `yaml:"priv-alg"`
PrivPasswd string `yaml:"priv-passwd"`
}