Mike Degatano 1b649fe5cd
Use newer StrEnum and IntEnum over Enum (#4521)
* Use newer StrEnum and IntEnum over Enum

* Fix validation issue and remove unnecessary .value calls

---------

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2023-09-06 12:21:04 -04:00

65 lines
1.1 KiB
Python

"""Const for host."""
from enum import StrEnum
PARAM_BOOT_ID = "_BOOT_ID"
PARAM_FOLLOW = "follow"
PARAM_SYSLOG_IDENTIFIER = "SYSLOG_IDENTIFIER"
class InterfaceMethod(StrEnum):
"""Configuration of an interface."""
DISABLED = "disabled"
STATIC = "static"
AUTO = "auto"
class InterfaceType(StrEnum):
"""Configuration of an interface."""
ETHERNET = "ethernet"
WIRELESS = "wireless"
VLAN = "vlan"
class AuthMethod(StrEnum):
"""Authentication method."""
OPEN = "open"
WEP = "wep"
WPA_PSK = "wpa-psk"
class WifiMode(StrEnum):
"""Wifi mode."""
INFRASTRUCTURE = "infrastructure"
MESH = "mesh"
ADHOC = "adhoc"
AP = "ap"
class HostFeature(StrEnum):
"""Host feature."""
DISK = "disk"
HAOS = "haos"
HOSTNAME = "hostname"
JOURNAL = "journal"
MOUNT = "mount"
NETWORK = "network"
OS_AGENT = "os_agent"
REBOOT = "reboot"
RESOLVED = "resolved"
SERVICES = "services"
SHUTDOWN = "shutdown"
TIMEDATE = "timedate"
class LogFormat(StrEnum):
"""Log format."""
JOURNAL = "application/vnd.fdo.journal"
JSON = "application/json"
TEXT = "text/plain"