This YANG module provides a data-model for the NTP service.
Copyright 2018-2020 Rubicon Communications, LLC.
Network Time Protocol daemon configuration for time keeping and services.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:ntp-config": {
- "netgate-ntp:system": {
- "netgate-ntp:namespace": "host",
- "netgate-ntp:enable": true
}, - "netgate-ntp:daemon": {
- "netgate-ntp:tinker": {
- "netgate-ntp:panic": 0
}, - "netgate-ntp:interfaces": {
- "netgate-ntp:interface": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
]
}, - "netgate-ntp:servers": {
- "netgate-ntp:server": [
- {
- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
]
}, - "netgate-ntp:tos": {
- "netgate-ntp:orphan": 0
}, - "netgate-ntp:restrictions": {
- "netgate-ntp:restriction": [
- {
- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
]
}, - "netgate-ntp:logconfigs": {
- "netgate-ntp:logconfig": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
]
}, - "netgate-ntp:parameters": {
- "netgate-ntp:enabled-flags": {
- "netgate-ntp:monitor": true
}, - "netgate-ntp:driftfile": "string",
- "netgate-ntp:statsdir": "string",
- "netgate-ntp:disabled-flags": {
- "netgate-ntp:monitor": true
}
}
}
}
}
Network Time Protocol daemon configuration for time keeping and services.
netgate.ntp.NtpConfig to be added to list
object (netgate.ntp.ntpconfig.System) The NTP system parameters not managed by the daemon. | |
object (netgate.ntp.ntpconfig.Daemon) NTP daemon configuration parameters. |
{- "netgate-ntp:system": {
- "netgate-ntp:namespace": "host",
- "netgate-ntp:enable": true
}, - "netgate-ntp:daemon": {
- "netgate-ntp:tinker": {
- "netgate-ntp:panic": 0
}, - "netgate-ntp:interfaces": {
- "netgate-ntp:interface": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
]
}, - "netgate-ntp:servers": {
- "netgate-ntp:server": [
- {
- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
]
}, - "netgate-ntp:tos": {
- "netgate-ntp:orphan": 0
}, - "netgate-ntp:restrictions": {
- "netgate-ntp:restriction": [
- {
- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
]
}, - "netgate-ntp:logconfigs": {
- "netgate-ntp:logconfig": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
]
}, - "netgate-ntp:parameters": {
- "netgate-ntp:enabled-flags": {
- "netgate-ntp:monitor": true
}, - "netgate-ntp:driftfile": "string",
- "netgate-ntp:statsdir": "string",
- "netgate-ntp:disabled-flags": {
- "netgate-ntp:monitor": true
}
}
}
}
Network Time Protocol daemon configuration for time keeping and services.
netgate.ntp.NtpConfig to be added or updated
object (netgate.ntp.NtpConfig) Network Time Protocol daemon configuration for time keeping and services. |
{- "netgate-ntp:ntp-config": {
- "netgate-ntp:system": {
- "netgate-ntp:namespace": "host",
- "netgate-ntp:enable": true
}, - "netgate-ntp:daemon": {
- "netgate-ntp:tinker": {
- "netgate-ntp:panic": 0
}, - "netgate-ntp:interfaces": {
- "netgate-ntp:interface": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
]
}, - "netgate-ntp:servers": {
- "netgate-ntp:server": [
- {
- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
]
}, - "netgate-ntp:tos": {
- "netgate-ntp:orphan": 0
}, - "netgate-ntp:restrictions": {
- "netgate-ntp:restriction": [
- {
- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
]
}, - "netgate-ntp:logconfigs": {
- "netgate-ntp:logconfig": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
]
}, - "netgate-ntp:parameters": {
- "netgate-ntp:enabled-flags": {
- "netgate-ntp:monitor": true
}, - "netgate-ntp:driftfile": "string",
- "netgate-ntp:statsdir": "string",
- "netgate-ntp:disabled-flags": {
- "netgate-ntp:monitor": true
}
}
}
}
}
Network Time Protocol daemon configuration for time keeping and services.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:daemon": {
- "netgate-ntp:tinker": {
- "netgate-ntp:panic": 0
}, - "netgate-ntp:interfaces": {
- "netgate-ntp:interface": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
]
}, - "netgate-ntp:servers": {
- "netgate-ntp:server": [
- {
- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
]
}, - "netgate-ntp:tos": {
- "netgate-ntp:orphan": 0
}, - "netgate-ntp:restrictions": {
- "netgate-ntp:restriction": [
- {
- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
]
}, - "netgate-ntp:logconfigs": {
- "netgate-ntp:logconfig": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
]
}, - "netgate-ntp:parameters": {
- "netgate-ntp:enabled-flags": {
- "netgate-ntp:monitor": true
}, - "netgate-ntp:driftfile": "string",
- "netgate-ntp:statsdir": "string",
- "netgate-ntp:disabled-flags": {
- "netgate-ntp:monitor": true
}
}
}
}
NTP daemon configuration parameters.
netgate.ntp.ntpconfig.Daemon to be added to list
object (netgate.ntp.ntpconfig.daemon.Tinker) Tinker options. | |
object (netgate.ntp.ntpconfig.daemon.Interfaces) Interface binding specifications. | |
object (netgate.ntp.ntpconfig.daemon.Servers) | |
object (netgate.ntp.ntpconfig.daemon.Tos) TOS options. | |
object (netgate.ntp.ntpconfig.daemon.Restrictions) | |
object (netgate.ntp.ntpconfig.daemon.Logconfigs) An ordered sequence of NTPD logconfig settings. | |
object (netgate.ntp.ntpconfig.daemon.Parameters) The NTP parameters managed by the NTP daemon. |
{- "netgate-ntp:tinker": {
- "netgate-ntp:panic": 0
}, - "netgate-ntp:interfaces": {
- "netgate-ntp:interface": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
]
}, - "netgate-ntp:servers": {
- "netgate-ntp:server": [
- {
- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
]
}, - "netgate-ntp:tos": {
- "netgate-ntp:orphan": 0
}, - "netgate-ntp:restrictions": {
- "netgate-ntp:restriction": [
- {
- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
]
}, - "netgate-ntp:logconfigs": {
- "netgate-ntp:logconfig": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
]
}, - "netgate-ntp:parameters": {
- "netgate-ntp:enabled-flags": {
- "netgate-ntp:monitor": true
}, - "netgate-ntp:driftfile": "string",
- "netgate-ntp:statsdir": "string",
- "netgate-ntp:disabled-flags": {
- "netgate-ntp:monitor": true
}
}
}
NTP daemon configuration parameters.
netgate.ntp.ntpconfig.Daemon to be added or updated
object (netgate.ntp.ntpconfig.Daemon) NTP daemon configuration parameters. |
{- "netgate-ntp:daemon": {
- "netgate-ntp:tinker": {
- "netgate-ntp:panic": 0
}, - "netgate-ntp:interfaces": {
- "netgate-ntp:interface": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
]
}, - "netgate-ntp:servers": {
- "netgate-ntp:server": [
- {
- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
]
}, - "netgate-ntp:tos": {
- "netgate-ntp:orphan": 0
}, - "netgate-ntp:restrictions": {
- "netgate-ntp:restriction": [
- {
- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
]
}, - "netgate-ntp:logconfigs": {
- "netgate-ntp:logconfig": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
]
}, - "netgate-ntp:parameters": {
- "netgate-ntp:enabled-flags": {
- "netgate-ntp:monitor": true
}, - "netgate-ntp:driftfile": "string",
- "netgate-ntp:statsdir": "string",
- "netgate-ntp:disabled-flags": {
- "netgate-ntp:monitor": true
}
}
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/interfaces" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:interfaces": {
- "netgate-ntp:interface": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
]
}
}
Interface binding specifications.
netgate.ntp.ntpconfig.daemon.Interfaces to be added to list
Array of objects (netgate.ntp.ntpconfig.daemon.interfaces.Interface) |
{- "netgate-ntp:interface": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
]
}
Interface binding specifications.
netgate.ntp.ntpconfig.daemon.Interfaces to be added or updated
object (netgate.ntp.ntpconfig.daemon.Interfaces) Interface binding specifications. |
{- "netgate-ntp:interfaces": {
- "netgate-ntp:interface": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
]
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/interfaces" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
creates netgate.ntp.ntpconfig.daemon.interfaces.Interface
netgate.ntp.ntpconfig.daemon.interfaces.Interface to be added to list
netgate-ntp:sequence | integer <int64> The sequence numbers provide an ordering for the list of interface commands. |
netgate-ntp:action | string (netgate.ntp.NtpInterfaceAction) Enum: "listen" "ignore" "drop" |
netgate-ntp:match-ip-prefix | string Match an IP prefix. |
netgate-ntp:match-all | boolean Match all interfaces. |
netgate-ntp:match-interface | string Match an interface name. |
{- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
returns netgate.ntp.ntpconfig.daemon.interfaces.Interface
sequence required | integer <int64> Id of interface |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/interfaces/interface=%7Bsequence%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:interface": {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
}
creates or updates netgate.ntp.ntpconfig.daemon.interfaces.Interface
sequence required | integer <int64> Id of interface |
netgate.ntp.ntpconfig.daemon.interfaces.Interface to be added or updated
object (netgate.ntp.ntpconfig.daemon.interfaces.Interface) |
{- "netgate-ntp:interface": {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "listen",
- "netgate-ntp:match-ip-prefix": "string",
- "netgate-ntp:match-all": true,
- "netgate-ntp:match-interface": "string"
}
}
removes netgate.ntp.ntpconfig.daemon.interfaces.Interface
sequence required | integer <int64> Id of interface |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/interfaces/interface=%7Bsequence%7D" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
An ordered sequence of NTPD logconfig settings.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/logconfigs" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:logconfigs": {
- "netgate-ntp:logconfig": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
]
}
}
An ordered sequence of NTPD logconfig settings.
netgate.ntp.ntpconfig.daemon.Logconfigs to be added to list
Array of objects (netgate.ntp.ntpconfig.daemon.logconfigs.Logconfig) |
{- "netgate-ntp:logconfig": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
]
}
An ordered sequence of NTPD logconfig settings.
netgate.ntp.ntpconfig.daemon.Logconfigs to be added or updated
object (netgate.ntp.ntpconfig.daemon.Logconfigs) An ordered sequence of NTPD logconfig settings. |
{- "netgate-ntp:logconfigs": {
- "netgate-ntp:logconfig": [
- {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
]
}
}
An ordered sequence of NTPD logconfig settings.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/logconfigs" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
creates netgate.ntp.ntpconfig.daemon.logconfigs.Logconfig
netgate.ntp.ntpconfig.daemon.logconfigs.Logconfig to be added to list
netgate-ntp:sequence | integer <int64> Logconfig options must be ordered. |
netgate-ntp:action | string (netgate.ntp.NtpLogAction) Enum: "set" "add" "delete" |
netgate-ntp:type | string (netgate.ntp.NtpLogType) Enum: "all" "info" "events" "statistics" "status" |
netgate-ntp:class | string (netgate.ntp.NtpLogClass) Enum: "all" "clock" "peer" "sys" "sync" |
{- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
returns netgate.ntp.ntpconfig.daemon.logconfigs.Logconfig
sequence required | integer <int64> Id of logconfig |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/logconfigs/logconfig=%7Bsequence%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:logconfig": {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
}
creates or updates netgate.ntp.ntpconfig.daemon.logconfigs.Logconfig
sequence required | integer <int64> Id of logconfig |
netgate.ntp.ntpconfig.daemon.logconfigs.Logconfig to be added or updated
object (netgate.ntp.ntpconfig.daemon.logconfigs.Logconfig) |
{- "netgate-ntp:logconfig": {
- "netgate-ntp:sequence": 0,
- "netgate-ntp:action": "set",
- "netgate-ntp:type": "all",
- "netgate-ntp:class": "all"
}
}
removes netgate.ntp.ntpconfig.daemon.logconfigs.Logconfig
sequence required | integer <int64> Id of logconfig |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/logconfigs/logconfig=%7Bsequence%7D" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
The NTP parameters managed by the NTP daemon.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/parameters" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:parameters": {
- "netgate-ntp:enabled-flags": {
- "netgate-ntp:monitor": true
}, - "netgate-ntp:driftfile": "string",
- "netgate-ntp:statsdir": "string",
- "netgate-ntp:disabled-flags": {
- "netgate-ntp:monitor": true
}
}
}
The NTP parameters managed by the NTP daemon.
netgate.ntp.ntpconfig.daemon.Parameters to be added to list
object (netgate.ntp.ntpconfig.daemon.parameters.EnabledFlags) Force monitor flags to enabled. | |
netgate-ntp:driftfile | string Full path name of the drift file. If not specified, /var/lib/ntp/drift. |
netgate-ntp:statsdir | string Full path name of the statistics directory. If not specified, /var/log/ntpstats |
object (netgate.ntp.ntpconfig.daemon.parameters.DisabledFlags) Force monitor flags to disabled. |
{- "netgate-ntp:enabled-flags": {
- "netgate-ntp:monitor": true
}, - "netgate-ntp:driftfile": "string",
- "netgate-ntp:statsdir": "string",
- "netgate-ntp:disabled-flags": {
- "netgate-ntp:monitor": true
}
}
The NTP parameters managed by the NTP daemon.
netgate.ntp.ntpconfig.daemon.Parameters to be added or updated
object (netgate.ntp.ntpconfig.daemon.Parameters) The NTP parameters managed by the NTP daemon. |
{- "netgate-ntp:parameters": {
- "netgate-ntp:enabled-flags": {
- "netgate-ntp:monitor": true
}, - "netgate-ntp:driftfile": "string",
- "netgate-ntp:statsdir": "string",
- "netgate-ntp:disabled-flags": {
- "netgate-ntp:monitor": true
}
}
}
The NTP parameters managed by the NTP daemon.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/parameters" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
Force monitor flags to disabled.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/parameters/disabled-flags" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:disabled-flags": {
- "netgate-ntp:monitor": true
}
}
Force monitor flags to disabled.
netgate.ntp.ntpconfig.daemon.parameters.DisabledFlags to be added to list
netgate-ntp:monitor | boolean If true, disable monitor. |
{- "netgate-ntp:monitor": true
}
Force monitor flags to disabled.
netgate.ntp.ntpconfig.daemon.parameters.DisabledFlags to be added or updated
object (netgate.ntp.ntpconfig.daemon.parameters.DisabledFlags) Force monitor flags to disabled. |
{- "netgate-ntp:disabled-flags": {
- "netgate-ntp:monitor": true
}
}
Force monitor flags to disabled.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/parameters/disabled-flags" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
Force monitor flags to enabled.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/parameters/enabled-flags" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:enabled-flags": {
- "netgate-ntp:monitor": true
}
}
Force monitor flags to enabled.
netgate.ntp.ntpconfig.daemon.parameters.EnabledFlags to be added to list
netgate-ntp:monitor | boolean If true, enable monitor. |
{- "netgate-ntp:monitor": true
}
Force monitor flags to enabled.
netgate.ntp.ntpconfig.daemon.parameters.EnabledFlags to be added or updated
object (netgate.ntp.ntpconfig.daemon.parameters.EnabledFlags) Force monitor flags to enabled. |
{- "netgate-ntp:enabled-flags": {
- "netgate-ntp:monitor": true
}
}
Force monitor flags to enabled.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/parameters/enabled-flags" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
returns netgate.ntp.ntpconfig.daemon.Restrictions
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/restrictions" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:restrictions": {
- "netgate-ntp:restriction": [
- {
- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
]
}
}
creates netgate.ntp.ntpconfig.daemon.Restrictions
netgate.ntp.ntpconfig.daemon.Restrictions to be added to list
Array of objects (netgate.ntp.ntpconfig.daemon.restrictions.Restriction) |
{- "netgate-ntp:restriction": [
- {
- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
]
}
creates or updates netgate.ntp.ntpconfig.daemon.Restrictions
netgate.ntp.ntpconfig.daemon.Restrictions to be added or updated
object (netgate.ntp.ntpconfig.daemon.Restrictions) |
{- "netgate-ntp:restrictions": {
- "netgate-ntp:restriction": [
- {
- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
]
}
}
removes netgate.ntp.ntpconfig.daemon.Restrictions
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/restrictions" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
creates netgate.ntp.ntpconfig.daemon.restrictions.Restriction
netgate.ntp.ntpconfig.daemon.restrictions.Restriction to be added to list
netgate-ntp:noquery | boolean If true, disable ntpq/ntpdc queries. |
netgate-ntp:kod | boolean If true, enable Kiss o' Death packets. |
netgate-ntp:address | string Network to restrict. |
netgate-ntp:noserve | boolean If true, disable service/everything except ntpq and ntpdc queries. |
netgate-ntp:limited | boolean If true, enable Kiss o' Death packets. |
netgate-ntp:nopeer | boolean If true, deny peer association packets. |
netgate-ntp:notrap | boolean If true, deny mode 6 control message trap service. |
netgate-ntp:nomodify | boolean If true, deny run-time config by ntpq and ntpdc. |
netgate-ntp:address-family | string (netgate.common.IpAddressFamily) Enum: "ipv4" "ipv6" |
{- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
returns netgate.ntp.ntpconfig.daemon.restrictions.Restriction
address required | string Id of restriction |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/restrictions/restriction=%7Baddress%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:restriction": {
- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
}
creates or updates netgate.ntp.ntpconfig.daemon.restrictions.Restriction
address required | string Id of restriction |
netgate.ntp.ntpconfig.daemon.restrictions.Restriction to be added or updated
object (netgate.ntp.ntpconfig.daemon.restrictions.Restriction) |
{- "netgate-ntp:restriction": {
- "netgate-ntp:noquery": true,
- "netgate-ntp:kod": true,
- "netgate-ntp:address": "string",
- "netgate-ntp:noserve": true,
- "netgate-ntp:limited": true,
- "netgate-ntp:nopeer": true,
- "netgate-ntp:notrap": true,
- "netgate-ntp:nomodify": true,
- "netgate-ntp:address-family": "ipv4"
}
}
removes netgate.ntp.ntpconfig.daemon.restrictions.Restriction
address required | string Id of restriction |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/restrictions/restriction=%7Baddress%7D" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/servers" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:servers": {
- "netgate-ntp:server": [
- {
- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
]
}
}
creates netgate.ntp.ntpconfig.daemon.Servers
netgate.ntp.ntpconfig.daemon.Servers to be added to list
Array of objects (netgate.ntp.ntpconfig.daemon.servers.Server) |
{- "netgate-ntp:server": [
- {
- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
]
}
creates or updates netgate.ntp.ntpconfig.daemon.Servers
netgate.ntp.ntpconfig.daemon.Servers to be added or updated
object (netgate.ntp.ntpconfig.daemon.Servers) |
{- "netgate-ntp:servers": {
- "netgate-ntp:server": [
- {
- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
]
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/servers" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
creates netgate.ntp.ntpconfig.daemon.servers.Server
netgate.ntp.ntpconfig.daemon.servers.Server to be added to list
netgate-ntp:host | string NTP server IP address or FQDN. |
netgate-ntp:noselect | boolean If true, disable time sync for this server, track stats only. |
netgate-ntp:prefer | boolean If true, favor this server more than others. |
netgate-ntp:operational-mode | string (netgate.ntp.NtpServerMode) Enum: "server" "pool" |
netgate-ntp:maxpoll | integer <int32> Maximum poll interval expressed as a power of 2 in seconds. |
netgate-ntp:iburst | boolean If true, send a burst of attempts to an unreachable server to speed up acquisition of time synchronization. |
{- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
returns netgate.ntp.ntpconfig.daemon.servers.Server
host required | string Id of server |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/servers/server=%7Bhost%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:server": {
- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
}
creates or updates netgate.ntp.ntpconfig.daemon.servers.Server
host required | string Id of server |
netgate.ntp.ntpconfig.daemon.servers.Server to be added or updated
object (netgate.ntp.ntpconfig.daemon.servers.Server) |
{- "netgate-ntp:server": {
- "netgate-ntp:host": "string",
- "netgate-ntp:noselect": true,
- "netgate-ntp:prefer": true,
- "netgate-ntp:operational-mode": "server",
- "netgate-ntp:maxpoll": 0,
- "netgate-ntp:iburst": true
}
}
removes netgate.ntp.ntpconfig.daemon.servers.Server
host required | string Id of server |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/servers/server=%7Bhost%7D" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/tinker" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:tinker": {
- "netgate-ntp:panic": 0
}
}
Tinker options.
netgate.ntp.ntpconfig.daemon.Tinker to be added to list
netgate-ntp:panic | integer <int64> Panic threshold in seconds. 0 disables. Default 1000. |
{- "netgate-ntp:panic": 0
}
Tinker options.
netgate.ntp.ntpconfig.daemon.Tinker to be added or updated
object (netgate.ntp.ntpconfig.daemon.Tinker) Tinker options. |
{- "netgate-ntp:tinker": {
- "netgate-ntp:panic": 0
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/tinker" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/tos" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:tos": {
- "netgate-ntp:orphan": 0
}
}
TOS options.
netgate.ntp.ntpconfig.daemon.Tos to be added to list
netgate-ntp:orphan | integer <int32> Orphan stratum in the range 1 through 16. |
{- "netgate-ntp:orphan": 0
}
TOS options.
netgate.ntp.ntpconfig.daemon.Tos to be added or updated
object (netgate.ntp.ntpconfig.daemon.Tos) TOS options. |
{- "netgate-ntp:tos": {
- "netgate-ntp:orphan": 0
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/daemon/tos" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/system" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:system": {
- "netgate-ntp:namespace": "host",
- "netgate-ntp:enable": true
}
}
The NTP system parameters not managed by the daemon.
netgate.ntp.ntpconfig.System to be added to list
netgate-ntp:namespace | string (netgate.common.NetworkNamespace) Enum: "host" "dataplane" |
netgate-ntp:enable | boolean If true, the NTP daemon is enabled. |
{- "netgate-ntp:namespace": "host",
- "netgate-ntp:enable": true
}
The NTP system parameters not managed by the daemon.
netgate.ntp.ntpconfig.System to be added or updated
object (netgate.ntp.ntpconfig.System) The NTP system parameters not managed by the daemon. |
{- "netgate-ntp:system": {
- "netgate-ntp:namespace": "host",
- "netgate-ntp:enable": true
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-config/system" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
Network Time Protocol daemon configuration for time keeping and services.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-state" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:ntp-state": {
- "netgate-ntp:peers": {
- "netgate-ntp:peer": [
- {
- "netgate-ntp:variables": {
- "netgate-ntp:variable": [
- {
- "netgate-ntp:name": "string",
- "netgate-ntp:decoded": "string",
- "netgate-ntp:raw": "string"
}
]
}, - "netgate-ntp:id": 0,
- "netgate-ntp:status": {
- "netgate-ntp:broadcast": true,
- "netgate-ntp:selection": "rejected",
- "netgate-ntp:event-count": 0,
- "netgate-ntp:last-event": "unspecified",
- "netgate-ntp:authentic": true,
- "netgate-ntp:raw": 0,
- "netgate-ntp:auth-enable": true,
- "netgate-ntp:persistent": true,
- "netgate-ntp:reachable": true
}
}
]
}
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-state/peers" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:peers": {
- "netgate-ntp:peer": [
- {
- "netgate-ntp:variables": {
- "netgate-ntp:variable": [
- {
- "netgate-ntp:name": "string",
- "netgate-ntp:decoded": "string",
- "netgate-ntp:raw": "string"
}
]
}, - "netgate-ntp:id": 0,
- "netgate-ntp:status": {
- "netgate-ntp:broadcast": true,
- "netgate-ntp:selection": "rejected",
- "netgate-ntp:event-count": 0,
- "netgate-ntp:last-event": "unspecified",
- "netgate-ntp:authentic": true,
- "netgate-ntp:raw": 0,
- "netgate-ntp:auth-enable": true,
- "netgate-ntp:persistent": true,
- "netgate-ntp:reachable": true
}
}
]
}
}
returns netgate.ntp.ntpstate.peers.Peer
id required | integer <int32> Id of peer |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-state/peers/peer=%7Bid%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:peer": {
- "netgate-ntp:variables": {
- "netgate-ntp:variable": [
- {
- "netgate-ntp:name": "string",
- "netgate-ntp:decoded": "string",
- "netgate-ntp:raw": "string"
}
]
}, - "netgate-ntp:id": 0,
- "netgate-ntp:status": {
- "netgate-ntp:broadcast": true,
- "netgate-ntp:selection": "rejected",
- "netgate-ntp:event-count": 0,
- "netgate-ntp:last-event": "unspecified",
- "netgate-ntp:authentic": true,
- "netgate-ntp:raw": 0,
- "netgate-ntp:auth-enable": true,
- "netgate-ntp:persistent": true,
- "netgate-ntp:reachable": true
}
}
}
The decoded peer status.
id required | integer <int32> Id of peer |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-state/peers/peer=%7Bid%7D/status" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:status": {
- "netgate-ntp:broadcast": true,
- "netgate-ntp:selection": "rejected",
- "netgate-ntp:event-count": 0,
- "netgate-ntp:last-event": "unspecified",
- "netgate-ntp:authentic": true,
- "netgate-ntp:raw": 0,
- "netgate-ntp:auth-enable": true,
- "netgate-ntp:persistent": true,
- "netgate-ntp:reachable": true
}
}
The peer variables of an association.
id required | integer <int32> Id of peer |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-state/peers/peer=%7Bid%7D/variables" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:variables": {
- "netgate-ntp:variable": [
- {
- "netgate-ntp:name": "string",
- "netgate-ntp:decoded": "string",
- "netgate-ntp:raw": "string"
}
]
}
}
returns netgate.ntp.ntpstate.peers.peer.variables.Variable
id required | integer <int32> Id of peer |
name required | string Id of variable |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-ntp:ntp-state/peers/peer=%7Bid%7D/variables/variable=%7Bname%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-ntp:variable": {
- "netgate-ntp:name": "string",
- "netgate-ntp:decoded": "string",
- "netgate-ntp:raw": "string"
}
}
operates on netgate.ntp.NtpConfigOperation
object (netgate.ntp.ntpconfigoperation.Input) |
{- "input": {
- "netgate-ntp:request": "string",
- "netgate-ntp:param": "string"
}
}
{- "output": {
- "netgate-ntp:stdout": "string"
}
}
operates on netgate.ntp.NtpControl
object (netgate.ntp.ntpcontrol.Input) |
{- "input": {
- "netgate-ntp:namespace": "host",
- "netgate-ntp:operation": "start"
}
}
{- "output": {
- "netgate-ntp:stdout": "string"
}
}
operates on netgate.ntp.NtpCoredump
object (netgate.ntp.ntpcoredump.Input) |
{- "input": {
- "netgate-ntp:namespace": "host",
- "netgate-ntp:operation": "enable"
}
}
{- "output": {
- "netgate-ntp:stdout": "string"
}
}