Timezone names as enumerated strings defined by IANA

Use timezone names defined in iana-timezones.yang, replacing
the type 'string' in standard ietf-system.yang

This enables CLI (tab complete) and NETCONF clients (dropdown)
to view available timezone strings, and the yang engine to
validate the input.
This commit is contained in:
Jon-Olov Vatn
2023-07-12 08:51:27 +02:00
committed by Joachim Wiberg
parent a43bdd94ab
commit 76c09ba3bd
3 changed files with 1715 additions and 0 deletions
+1
View File
@@ -32,6 +32,7 @@ sysrepoctl -s $SEARCH \
-e ntp \
-e ntp-udp-port \
-e timezone-name \
-i iana-timezones@2013-11-19.yang -g wheel -p 0660 \
-i nc-notifications@2008-07-14.yang -g wheel -p 0660 \
-i notifications@2008-07-14.yang -g wheel -p 0660 \
-i ietf-keystore@2019-07-02.yang -g wheel -p 0660 \
File diff suppressed because it is too large Load Diff
@@ -6,6 +6,9 @@ module infix-system {
import ietf-system {
prefix sys;
}
import iana-timezones {
prefix iana-tz;
}
include infix-system-software;
organization "KernelKit";
@@ -14,6 +17,7 @@ module infix-system {
revision 2023-07-04 {
description "Updating/adding deviation specifications:
- timezone-name (use tz defs from iana-timezone.yang)
- timezone-utc-offset (updated path for 'not-supported')
- radius ('not-supported')
- dns-resolver port ('not-supported')
@@ -41,6 +45,12 @@ module infix-system {
}
}
deviation "/sys:system/sys:clock/sys:timezone/sys:timezone-name/sys:timezone-name" {
deviate replace {
type iana-tz:iana-timezone;
}
}
deviation "/sys:system/sys:clock/sys:timezone/sys:timezone-utc-offset" {
deviate not-supported;
}