lxc-test-cloneconfig revision d0a6bd39400a6d14cfec94ad647f3af1bda1e321
0N/A# lxc: linux Container library 0N/A# Serge Hallyn <serge.hallyn@ubuntu.com> 0N/A# This is a test script for the lxc-user-nic program 0N/A# This library is free software; you can redistribute it and/or 0N/A# modify it under the terms of the GNU Lesser General Public 0N/A# License as published by the Free Software Foundation; either 0N/A# version 2.1 of the License, or (at your option) any later version. 0N/A# This library is distributed in the hope that it will be useful, 0N/A# but WITHOUT ANY WARRANTY; without even the implied warranty of 0N/A# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 0N/A# Lesser General Public License for more details. 2362N/A# You should have received a copy of the GNU Lesser General Public 2362N/A# License along with this library; if not, write to the Free Software 0N/A# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA echo "unequal number of $desc" echo "Original has $n1, clone has $n2" [ $DONE -eq 1 ] && echo "PASS" || echo "FAIL" echo "hwaddr $addr was not changed" echo "Failed to find $nline in:" lxc.network.link = lxcbr0 # Simple nic with hwaddr; verify hwaddr changed lxc.network.link = lxcbr0 # No nics, but nic from include lxc.network.link = lxcbr0 lxc.hook.start = /bin/bash lxc.include = $s/1.include # No nics, one clone hook in /bin lxc.hook.start = /bin/bash # Figure out container dirname # No nics, one clone hook in $container lxc.hook.start = $CONTAINER_PATH/x1 # verify that # nics did not change # verify hwaddr, if any changed # verify hooks are correct