Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions files/build_templates/init_cfg.json.j2
Original file line number Diff line number Diff line change
Expand Up @@ -212,5 +212,10 @@
"admin_state": "enabled",
"vrf": "default"
}
},
Comment thread
Verma-Anukul marked this conversation as resolved.
Outdated
"VERSIONS": {
"SOFTWARE": {
"VERSION": "{{build_version}}"
}
}
}
3 changes: 3 additions & 0 deletions src/sonic-yang-models/tests/files/sample_config_db.json
Original file line number Diff line number Diff line change
Expand Up @@ -1372,6 +1372,9 @@
"VERSIONS": {
"DATABASE": {
"VERSION": "version_1_0_3"
},
"SOFTWARE": {
"VERSION": "sonic_202411_01_03"
}
},
"TELEMETRY": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
]
},
"sonic-ntp:NTP_KEY": {
"NTP_KEYS_LIST": [
"NTP_KEY_LIST": [
{
"id": 10,
"value": "bHVtb3M="
Expand Down Expand Up @@ -422,7 +422,7 @@
"NTP_KEY_VALID": {
"sonic-ntp:sonic-ntp": {
"sonic-ntp:NTP_KEY": {
"NTP_KEYS_LIST": [
"NTP_KEY_LIST": [
{
"id": 20,
"type": "md5",
Expand All @@ -448,7 +448,7 @@
"NTP_KEY_ID_INVALID": {
"sonic-ntp:sonic-ntp": {
"sonic-ntp:NTP_KEY": {
"NTP_KEYS_LIST": [
"NTP_KEY_LIST": [
{
"id": 100000
}
Expand All @@ -459,7 +459,7 @@
"NTP_KEY_TRUSTED_INVALID": {
"sonic-ntp:sonic-ntp": {
"sonic-ntp:NTP_KEY": {
"NTP_KEYS_LIST": [
"NTP_KEY_LIST": [
{
"id": 20,
"trusted": "nope"
Expand All @@ -471,7 +471,7 @@
"NTP_KEY_TYPE_INVALID": {
"sonic-ntp:sonic-ntp": {
"sonic-ntp:NTP_KEY": {
"NTP_KEYS_LIST": [
"NTP_KEY_LIST": [
{
"id": 20,
"type": "md6"
Expand All @@ -483,7 +483,7 @@
"NTP_KEY_VALUE_INVALID": {
"sonic-ntp:sonic-ntp": {
"sonic-ntp:NTP_KEY": {
"NTP_KEYS_LIST": [
"NTP_KEY_LIST": [
{
"id": 20,
"value": ""
Expand Down
11 changes: 8 additions & 3 deletions src/sonic-yang-models/yang-models/sonic-ntp.yang
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,11 @@ module sonic-ntp {
"Add extended configuration options";
}

revision 2025-07-21 {
description
"Corrected NTP_KEY_LIST list name";
}

typedef association-type {
description "NTP server association type";
type enumeration {
Expand Down Expand Up @@ -192,7 +197,7 @@ module sonic-ntp {
leaf key {
description "NTP server key ID";
type leafref {
path /ntp:sonic-ntp/ntp:NTP_KEY/ntp:NTP_KEYS_LIST/ntp:id;
path /ntp:sonic-ntp/ntp:NTP_KEY/ntp:NTP_KEY_LIST/ntp:id;
}
}

Expand Down Expand Up @@ -234,7 +239,7 @@ module sonic-ntp {

description "NTP authentication keys inventory";

list NTP_KEYS_LIST {
list NTP_KEY_LIST {
description "NTP authentication keys inventory";
key "id";

Expand All @@ -261,7 +266,7 @@ module sonic-ntp {
default md5;
description "NTP authentication key type";
}
} /* end of list NTP_KEYS_LIST */
} /* end of list NTP_KEY_LIST */

} /* end of container NTP_KEY */

Expand Down
16 changes: 15 additions & 1 deletion src/sonic-yang-models/yang-models/sonic-versions.yang
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ module sonic-versions {

description "VERSIONS YANG Module for SONiC OS";

revision 2025-07-21 {
description "Added software version support";
}

revision 2020-04-10 {
description "First Revision";
}
Expand All @@ -16,7 +20,7 @@ module sonic-versions {

container VERSIONS {

description "DATABASE SCHEMA VERSIONS part of config_db.json";
description "DATABASE SCHEMA & SOFTWARE VERSIONS part of config_db.json";

container DATABASE {

Expand All @@ -28,6 +32,16 @@ module sonic-versions {
}
}
/* end of container DATABASE */

container SOFTWARE {

leaf VERSION {
type string {
length 1..255;
}
}
}
/* end of container DATABASE */
}
/* end of container VERSIONS */
}
Expand Down
Loading