How to configure veth through LuCI

Hi there,

I tried to configure veth through LuCI, The following is my uci setting, interface 'WAN' will get IP from br-lan.
if I want 'WAN' gets ip from wan side, should I create a new bridge or a new namespace, how to achieve that?

config device
        option name 'br-lan'
        option type 'bridge'
        list ports 'lan0'
        list ports 'lan1'
        list ports 'lan2'
        list ports 'lan3'
        list ports 'veth0'

config device
        option type 'veth'
        option name 'veth0'
        option mtu '1500'
        option macaddr '00:11:06:04:20:22'
        option peer_name 'veth1'
        option peer_macaddr '00:11:06:04:20:23'
        option ipv6 '0'

config interface 'WAN'
        option proto 'dhcp'
        option device 'veth1'
  1. Network -> Interfaces -> Devices -> Add Device Configuration...
  2. Device type: Virtual Ethernet, fill out rest, Save
  3. Save & Apply

Thanks, I have set as you said, but how can I get IP from wan side?

Or can you give an usage example of veth on OpenWrt, Thanks.

So what is he doing it for?