mirror of
git://github.com/lxc/lxc
synced 2025-09-02 12:09:33 +00:00
Minor lxc config template layout fix
Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com> Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
This commit is contained in:
committed by
Daniel Lezcano
parent
6e1d9b94b6
commit
b08ee0ce9a
@@ -41,7 +41,7 @@ copy_configuration()
|
|||||||
nics=`grep -e '^lxc\.network\.type[ \t]*=[ \t]*veth' $path/config | wc -l`
|
nics=`grep -e '^lxc\.network\.type[ \t]*=[ \t]*veth' $path/config | wc -l`
|
||||||
if [ $nics -eq 1 ]; then
|
if [ $nics -eq 1 ]; then
|
||||||
grep -q "^lxc.network.hwaddr" $path/config || cat <<EOF >> $path/config
|
grep -q "^lxc.network.hwaddr" $path/config || cat <<EOF >> $path/config
|
||||||
lxc.network.hwaddr= 00:16:3e:$(openssl rand -hex 3| sed 's/\(..\)/\1:/g; s/.$//')
|
lxc.network.hwaddr = 00:16:3e:$(openssl rand -hex 3| sed 's/\(..\)/\1:/g; s/.$//')
|
||||||
EOF
|
EOF
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@@ -319,7 +319,7 @@ copy_configuration()
|
|||||||
nics=`grep -e '^lxc\.network\.type[ \t]*=[ \t]*veth' $path/config | wc -l`
|
nics=`grep -e '^lxc\.network\.type[ \t]*=[ \t]*veth' $path/config | wc -l`
|
||||||
if [ $nics -eq 1 ]; then
|
if [ $nics -eq 1 ]; then
|
||||||
grep -q "^lxc.network.hwaddr" $path/config || cat <<EOF >> $path/config
|
grep -q "^lxc.network.hwaddr" $path/config || cat <<EOF >> $path/config
|
||||||
lxc.network.hwaddr= 00:16:3e:$(openssl rand -hex 3| sed 's/\(..\)/\1:/g; s/.$//')
|
lxc.network.hwaddr = 00:16:3e:$(openssl rand -hex 3| sed 's/\(..\)/\1:/g; s/.$//')
|
||||||
EOF
|
EOF
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user