xref: /netbsd-src/external/mpl/dhcp/dist/keama/tests/existsbx4.out (revision 3587d6f89c746bbb4f886219ddacd41ace480ecf)
1{
2  # exists boolean expression
3  # empty configs are not accepted by Kea
4  "Dhcp4": {
5    "valid-lifetime": 1800,
6    "client-classes": [
7      # use exists in a reductible match if
8      {
9        "name": "reductible",
10        /// from: match if exists dhcp.host-name
11        "test": "option[12].exists"
12      }
13    ]
14//  # if test is a boolean too
15//  "statement": {
16//    "if": {
17//      "condition": {
18//        "exists": {
19//          "universe": "dhcp",
20//          "name": "host-name",
21//          "code": 12
22//        }
23//      },
24//      "then": [
25//        {
26//          /// Kea does not support yet log statements
27//          /// Reference Kea #234
28//          "log": {
29//            "priority": "info",
30//            "message": {
31//              "concat": {
32//                "left": "hostname:",
33//                "right": {
34//                  "option": {
35//                    "universe": "dhcp",
36//                    "name": "host-name",
37//                    "code": 12
38//                  }
39//                }
40//              }
41//            }
42//          }
43//        }
44//      ]
45//    }
46//  }
47  }
48}
49