]> git.ipfire.org Git - thirdparty/strongswan.git/commitdiff
testing: Copy guest-specific files after default files
authorTobias Brunner <tobias@strongswan.org>
Thu, 20 Jul 2023 13:28:51 +0000 (15:28 +0200)
committerTobias Brunner <tobias@strongswan.org>
Thu, 20 Jul 2023 13:59:21 +0000 (15:59 +0200)
This allows overriding some files per guest.

testing/scripts/build-guestimages
testing/scripts/restore-defaults

index cef1a8297bc3883607b012784b996c37ea1be660..34cd91fe5cba3c5bbd9c6ca9169f95339d1f9b08 100755 (executable)
@@ -45,8 +45,8 @@ do
        execute "qemu-nbd -c $NBDEV $IMGDIR/$host.$IMGEXT" 0
        partprobe $NBDEV
        execute "mount $NBDPARTITION $LOOPDIR" 0
-       execute "cp -rf $HOSTSDIR/${host}/etc $LOOPDIR" 0
        execute "cp -rf $HOSTSDIR/default/* $LOOPDIR" 0
+       execute "cp -rf $HOSTSDIR/${host}/etc $LOOPDIR" 0
        execute_chroot "ldconfig" 0
        execute "mkdir $LOOPDIR/etc/pts" 0
 
index 95f3e5d84421ccf8433014be99c07c901bc6b774..0ef08f266fb20dde5930d82e71e89649b4a715ef 100755 (executable)
@@ -35,7 +35,7 @@ then
        for host in `ls $TESTSDIR/${testname}/hosts`
        do
                eval HOSTLOGIN="root@`echo $HOSTNAMEIPV4 | sed -n -e "s/^.*${host},//gp" | awk -F, '{ print $1 }' | awk '{ print $1 }'`"
-               scp $SSHCONF -r $HOSTCONFIGDIR/${host}/etc $HOSTLOGIN:/ > /dev/null 2>&1
                scp $SSHCONF -r $HOSTCONFIGDIR/default/etc $HOSTLOGIN:/ > /dev/null 2>&1
+               scp $SSHCONF -r $HOSTCONFIGDIR/${host}/etc $HOSTLOGIN:/ > /dev/null 2>&1
        done
 fi