|
@@ -792,15 +792,30 @@ DHCPv4 module, it must be listed in the "hooks-libraries" element of the
|
|
@code
|
|
@code
|
|
"Dhcp4": {
|
|
"Dhcp4": {
|
|
:
|
|
:
|
|
- "hooks-libraries": [ "/usr/local/lib/example.so" ]
|
|
|
|
|
|
+ "hooks-libraries": [
|
|
|
|
+ {
|
|
|
|
+ "library": "/usr/local/lib/example.so"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ :
|
|
|
|
+ }
|
|
:
|
|
:
|
|
}
|
|
}
|
|
@endcode
|
|
@endcode
|
|
(Note that "hooks" is plural.)
|
|
(Note that "hooks" is plural.)
|
|
|
|
|
|
|
|
+Each entry in the "hooks-libraries" list is a structure (a "map" in JSON
|
|
|
|
+parlance) that holds the following element:
|
|
|
|
+- library - the name of the library to load. This must be a string.
|
|
|
|
+
|
|
The DHCPv4 server will load the library and execute the callouts each time a
|
|
The DHCPv4 server will load the library and execute the callouts each time a
|
|
request is received.
|
|
request is received.
|
|
|
|
|
|
|
|
+@note The syntax of the hooks-libraries configuration element has changed
|
|
|
|
+since kea 0.9.2 (in that version, "hooks-libraries" was just a list of
|
|
|
|
+libraries). This change is in preparation for the introduction of
|
|
|
|
+library-=specific parameters, which will be added to Kea in a version after 1.0.
|
|
|
|
+
|
|
@note The above assumes that the hooks library will be used with a version of
|
|
@note The above assumes that the hooks library will be used with a version of
|
|
Kea that is dynamically-linked. For information regarding running
|
|
Kea that is dynamically-linked. For information regarding running
|
|
hooks libraries against a statically-linked Kea, see
|
|
hooks libraries against a statically-linked Kea, see
|
|
@@ -1184,8 +1199,15 @@ as separate elements of the hooks-libraries configuration element, e.g.
|
|
@code
|
|
@code
|
|
"Dhcp4": {
|
|
"Dhcp4": {
|
|
:
|
|
:
|
|
- "hooks-libraries": [ "/usr/lib/library1.so", "/opt/library2.so" ]
|
|
|
|
|
|
+ "hooks-libraries": [
|
|
|
|
+ {
|
|
|
|
+ "library": "/usr/lib/library1.so"
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ "library": "/opt/library2.so"
|
|
|
|
+ }
|
|
:
|
|
:
|
|
|
|
+ ]
|
|
}
|
|
}
|
|
@endcode
|
|
@endcode
|
|
|
|
|