Skip to main content

dtctl router update-static-route

Usage​

dtctl router update-static-route [flags]

Aliases​

usr

Description​

Replace an existing static route (matched by its current destination and next hop) with a new destination and next hop.

Example​

dtctl router update-static-route --router-id <router-id> --destination 10.20.0.0/24 --next-hop 10.0.0.5 --new-destination 10.30.0.0/24 --new-next-hop 10.0.0.6

Response​

In text output (the default), this command returns the following columns: ID, Name, Admin State Up, Status, External Gateway Info, Static Routes, Description, Flavor ID, Created At, Updated At, Revision Number.

Pass --output json to get the full response object instead.

Flags​

OptionDescription
--destination, -dCurrent destination CIDR for the static route to be updated (required)
--new-destination, -tNew destination CIDR for the static route. Defaults to the current destination
--new-next-hop, -pNew next hop for the static route. Defaults to the current next hop
--next-hop, -nCurrent next hop for the static route to be updated (required)
--router-id, -iRouter ID to update static route for (required)
CommandDescription
dtctl router listList routers
dtctl router showShow a router
dtctl router createCreate a router
dtctl router updateRename a router
dtctl router deleteDelete a router
dtctl router delete-external-gatewayRemove the external gateway
dtctl router delete-interfaceDetach an interface
dtctl router delete-static-routeDelete a static route
dtctl router add-static-routeAdd a static route
dtctl router attach-external-gatewayAttach an external gateway
dtctl router attach-interfaceAttach an internal interface
dtctl router externalsList networks with external access
dtctl router interfacesList a router's interfaces
dtctl router restartRestart a router
dtctl router static-routesList a router's static routes

Global Flags​

OptionDescription
--api-urlSend this command to a different API endpoint, e.g. a test environment (default "https://console.dt.net.tr/api/v1")
--config, -cSpecify a custom config file
Default: ~/.config/dtctl/config.yaml
--no-headersOmit the column headers, for scripting
Default: false
--output, -oOutput format: text, wide, vertical, json. text fits the terminal, wide never truncates, vertical prints one field per line
Default: text