This YANG module provides a Netgate-defined data-model for GRE data.
Copyright 2018-2020 Rubicon Communications, LLC.
Example URL
Configuration for GRE tunnels.
netgate.gre.GreConfig
Internal error
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-gre:gre-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)) }
Example URL
Configuration for GRE tunnels.
netgate.gre.GreConfig to be added to list
gre-table | object (netgate.gre.greconfig.GreTable) |
Object created
Internal error
Object already exists
Example URL
Configuration for GRE tunnels.
netgate.gre.GreConfig to be added or updated
netgate-gre:gre-config | object (netgate.gre.GreConfig) |
Object created
Object modified
Internal error
Example URL
Configuration for GRE tunnels.
Object deleted
Internal error
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-gre:gre-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)) }
Example URL
GRE table.
netgate.gre.greconfig.GreTable
Internal error
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-gre:gre-config/netgate-gre:gre-table" 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)) }
Example URL
GRE table.
netgate.gre.greconfig.GreTable to be added to list
tunnel | Array of objects (netgate.gre.greconfig.gretable.Tunnel) GRE tunnel configuration. |
Object created
Internal error
Object already exists
Example URL
GRE table.
netgate.gre.greconfig.GreTable to be added or updated
netgate-gre:gre-table | object (netgate.gre.greconfig.GreTable) |
Object created
Object modified
Internal error
Example URL
GRE table.
Object deleted
Internal error
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-gre:gre-config/netgate-gre:gre-table" 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)) }
Example URL
GRE tunnel configuration.
netgate.gre.greconfig.gretable.Tunnel to be added to list
tunnel-type | string (netgate.gre.GreTunnelType) Enum: "l3" "teb" "erspan" |
instance | integer <int64> Each GRE tunnel creates an interface. The
created interface will be named 'gre |
erspan-session-id | integer <int64> VNI value, u24. |
encap-route-table | string Encapsulation route table name. |
name | string The GRE tunnel identifier. A unique name for this GRE tunnel. |
src-ip-address | string The source IP address. |
dst-ip-address | string The destination IP address. |
Object created
Internal error
Object already exists
Example URL
GRE tunnel configuration.
name required | string Id of tunnel |
netgate.gre.greconfig.gretable.Tunnel
Internal error
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-gre:gre-config/netgate-gre:gre-table/netgate-gre:tunnel=%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)) }
Example URL
GRE tunnel configuration.
name required | string Id of tunnel |
netgate.gre.greconfig.gretable.Tunnel to be added to list
tunnel-type | string (netgate.gre.GreTunnelType) Enum: "l3" "teb" "erspan" |
instance | integer <int64> Each GRE tunnel creates an interface. The
created interface will be named 'gre |
erspan-session-id | integer <int64> VNI value, u24. |
encap-route-table | string Encapsulation route table name. |
name | string The GRE tunnel identifier. A unique name for this GRE tunnel. |
src-ip-address | string The source IP address. |
dst-ip-address | string The destination IP address. |
Object created
Internal error
Object already exists
Example URL
GRE tunnel configuration.
name required | string Id of tunnel |
netgate.gre.greconfig.gretable.Tunnel to be added or updated
netgate-gre:tunnel | object (netgate.gre.greconfig.gretable.Tunnel) |
Object created
Object modified
Internal error
Example URL
GRE tunnel configuration.
name required | string Id of tunnel |
Object deleted
Internal error
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-gre:gre-config/netgate-gre:gre-table/netgate-gre:tunnel=%7Bname%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)) }
Example URL
State of the GRE tunnels.
netgate.gre.GreState
Internal error
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-gre:gre-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)) }
Example URL
GRE table.
netgate.gre.grestate.GreTable
Internal error
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-gre:gre-state/netgate-gre:gre-table" 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)) }