Esempio n. 1
0
    def __init__(self):
        self.name = StringLeaf('default')
        self.type = DNSResolverType.UDP.name
        self.ip_address = StringLeaf(RESOLVER_DEFAULT_UPSTREAM_IP_ADDRESS_V4)
        self.ip_address6 = StringLeaf()

        self.timeout = IntLeaf(RESOLVER_DEFAULT_TIMEOUT)
        self.proxy = StringLeaf()

        self.lifetime = IntLeaf(CACHE_DEFAULT_LIFETIME)  # 60 * 15 = 15 minute

        super().__init__()
Esempio n. 2
0
 class AP(Branch):
     enabled = BooleanLeaf(True)
     channel = IntLeaf(1)
     password = StringLeaf('password')
     mac_acl_list = ListLeaf([
         '00:00:00:00:00:00',
     ])
Esempio n. 3
0
class Config(Root):
    version = StringLeaf('0.1.0')

    class Auth(Branch):
        username = StringLeaf('rex')
        password = StringLeaf('password')

    class Wireless(Branch):
        class AP(Branch):
            enabled = BooleanLeaf(True)
            channel = IntLeaf(1)
            password = StringLeaf('password')
            mac_acl_list = ListLeaf([
                '00:00:00:00:00:00',
            ])

    class NotExistBranch(Branch):
        pass

    not_exist_leaf = StringLeaf()
Esempio n. 4
0
 class Auth(Branch):
     username = StringLeaf('rex')
     password = StringLeaf('password')
Esempio n. 5
0
 class Service(Branch):
     bind = StringLeaf(DEFAULT_HOST)
     port = IntLeaf(DEFAULT_PORT)
Esempio n. 6
0
 class Common(Branch):
     sentry_dsn = StringLeaf()
Esempio n. 7
0
 class Default(Branch):
     resolver = StringLeaf('default')
Esempio n. 8
0
 class Cache(Branch):
     uri = StringLeaf(CACHE_DEFAULT_URI)
     storage_lifetime = IntLeaf(CACHE_DEFAULT_STORAGE_LIFETIME)