cfg/pkg/nut/main.k

36 lines
647 B
Plaintext

schema Ups:
"""Schema for ups.conf sections"""
driver: str
port?: str
desc?: str
vendorid?: str
productid?: str
product?: str
serial?: str
vendor?: str
bus?: str
pollonly?: "enabled" | "disabled"
pollinterval?: int
schema User:
"""Schema for upsd.users sections"""
password: str
actions?: [str]
instcmds?: [str]
upsmon?: "primary" | "secondary"
schema Listen:
"""Schema for listen socket address"""
address: str = "::"
port: int = 3493
schema Nut:
"""Schema for NUT configuration"""
listen = Listen()
ups: {str:Ups} = {}
users: {str:User} = {}