No default route on this DHCP interface
Instead use this DHCP interface as the default route
# No default route on this DHCP interface
- type: interface
name: nic2
use_dhcp: true
defroute: false
# Instead use this DHCP interface as the default route
- type: interface
name: nic3
use_dhcp: true
Copy to ClipboardCopied!Toggle word wrapToggle overflow
注意
defroute 参数仅适用于通过 DHCP 获取的路由。
要在带有静态 IP 的接口上设置静态路由,请指定到子网的路由。例如,您可以通过内部 API 网络上的 172.17.0.1 网关设置到 10.1.2.0/24 子网的路由: