@@ -476,7 +476,7 @@ Will result in::
476476 wireless-channel 1
477477 wireless-essid freifunk
478478 wireless-mode ad-hoc
479-
479+
480480
481481WPA2 Personal (Pre-Shared Key)
482482~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -530,3 +530,49 @@ Will be rendered as follows::
530530 wpa_key_mgmt=WPA-PSK
531531 wpa_passphrase=passphrase012345
532532 wpa_pairwise=TKIP CCMP
533+
534+ NTP settings
535+ ------------
536+
537+ The Network Time Protocol settings reside in the ``ntp `` key of the
538+ *configuration dictionary *, which is a custom NetJSON extension not present in
539+ the original NetJSON RFC.
540+
541+ The ``ntp `` key must contain a dictionary, the allowed options are:
542+
543+ +-------------------+---------+---------------------+
544+ | key name | type | function |
545+ +===================+=========+=====================+
546+ | ``enabled `` | boolean | ntp client enabled |
547+ +-------------------+---------+---------------------+
548+ | ``enable_server `` | boolean | ntp server enabled |
549+ +-------------------+---------+---------------------+
550+ | ``server `` | list | list of ntp servers |
551+ +-------------------+---------+---------------------+
552+
553+ NTP settings example
554+ ~~~~~~~~~~~~~~~~~~~~
555+
556+ The following *configuration dictionary * :
557+
558+ .. code-block :: python
559+
560+ {
561+ " ntp" : {
562+ " enabled" : True ,
563+ " enable_server" : False ,
564+ " server" : [
565+ " 0.openwrt.pool.ntp.org" ,
566+ " 1.openwrt.pool.ntp.org" ,
567+ " 2.openwrt.pool.ntp.org" ,
568+ " 3.openwrt.pool.ntp.org"
569+ ]
570+ }
571+
572+ Will be rendered as follows::
573+
574+ config: / etc/ ntp.conf
575+ server 0. openwrt.pool.ntp.org
576+ server 1. openwrt.pool.ntp.org
577+ server 2. openwrt.pool.ntp.org
578+ server 3. openwrt.pool.ntp.org
0 commit comments