1
0
mirror of https://github.com/CumulusNetworks/ifupdown2.git synced 2024-05-06 15:54:50 +00:00

debian: ifupdown2.postinst: refine 'iface lo' regex

Ticket: CM-14362
Reviewed By: Roopa, Nikhil G
Testing Done:

Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
This commit is contained in:
Julien Fortin
2017-01-17 15:49:23 +03:00
parent b8b579f36d
commit bea8c8d105

View File

@@ -56,7 +56,7 @@ case "$1" in
# Generic stuff done on all configurations
if [ -f /etc/network/interfaces ] ; then
if ! grep -q "^[[:space:]]*iface[[:space:]]\+lo0\?[[:space:]]\+inet[[:space:]]\+loopback\>" /etc/network/interfaces ; then
if ! grep -q -E "^[[:space:]]*iface[[:space:]]+l[o0]([[:space:]]+inet([[:space:]]+loopback)?)?[[:space:]]*$" /etc/network/interfaces ; then
report_warn "No 'iface lo' definition found in /etc/network/interfaces"
fi