Alexander Filippov | 83aa32a | 2020-06-08 12:51:56 +0300 | [diff] [blame] | 1 | #!/bin/sh -eu |
2 | |||||
3 | VLAN='VLAN=eth0.4004' | ||||
4 | ETH0_CFG='/etc/systemd/network/00-bmc-eth0.network' | ||||
5 | |||||
6 | if ( ! grep -q "${VLAN}" ${ETH0_CFG} ); then | ||||
7 | sed -i "/^\[Network\]$/a ${VLAN}" ${ETH0_CFG} | ||||
8 | fi |