|
|
e9bfca |
From 2f258581f9c706c5c92d0986e7bae8583ce145dd Mon Sep 17 00:00:00 2001
|
|
|
151578 |
From: "Richard W.M. Jones" <rjones@redhat.com>
|
|
|
151578 |
Date: Thu, 2 Oct 2014 16:44:00 +0100
|
|
|
151578 |
Subject: [PATCH] RHEL 7: Revert "tests: rsync: Skip this test when the backend
|
|
|
151578 |
is libvirt."
|
|
|
151578 |
|
|
|
151578 |
This reverts commit 765dc6237ce7b93dd2f33d99be53eae92e048a7a.
|
|
|
151578 |
---
|
|
|
151578 |
tests/rsync/test-rsync.sh | 35 +++++++----------------------------
|
|
|
151578 |
1 file changed, 7 insertions(+), 28 deletions(-)
|
|
|
151578 |
|
|
|
151578 |
diff --git a/tests/rsync/test-rsync.sh b/tests/rsync/test-rsync.sh
|
|
|
151578 |
index c6d98cfd1..246396276 100755
|
|
|
151578 |
--- a/tests/rsync/test-rsync.sh
|
|
|
151578 |
+++ b/tests/rsync/test-rsync.sh
|
|
|
151578 |
@@ -26,33 +26,10 @@ skip_if_skipped
|
|
|
151578 |
skip_unless rsync --help
|
|
|
151578 |
skip_unless_feature_available rsync
|
|
|
151578 |
|
|
|
151578 |
-# Get host IP address. XXX Bit of a hack.
|
|
|
151578 |
-backend="$(guestfish get-backend)"
|
|
|
151578 |
-case "$backend" in
|
|
|
151578 |
- direct)
|
|
|
151578 |
- ip=169.254.2.2
|
|
|
151578 |
- listen_address=localhost
|
|
|
151578 |
- ;;
|
|
|
151578 |
- libvirt|libvirt:*)
|
|
|
151578 |
- # This would work, except that the host firewall is effective
|
|
|
151578 |
- # on virbr0, and that is likely to block the non-standard port
|
|
|
151578 |
- # number that we listen on.
|
|
|
151578 |
-# ip="$(ip -4 -o address show virbr0 |
|
|
|
151578 |
-# awk '{print $4}' |
|
|
|
151578 |
-# awk -F/ '{print $1}')"
|
|
|
151578 |
-# listen_address="$ip"
|
|
|
151578 |
- echo "$0: skipping test because host firewall will probably prevent this test from working"
|
|
|
151578 |
- exit 77
|
|
|
151578 |
- ;;
|
|
|
151578 |
- uml)
|
|
|
151578 |
- echo "$0: skipping test because networking is not available in the UML backend"
|
|
|
151578 |
- exit 77
|
|
|
151578 |
- ;;
|
|
|
151578 |
- *)
|
|
|
151578 |
- echo "$0: don't know how to get IP address of backend $backend"
|
|
|
151578 |
- exit 77
|
|
|
151578 |
- ;;
|
|
|
151578 |
-esac
|
|
|
151578 |
+if [ "$(guestfish get-backend)" = "uml" ]; then
|
|
|
151578 |
+ echo "$0: skipping test because networking is not available in the UML backend"
|
|
|
151578 |
+ exit 77
|
|
|
151578 |
+fi
|
|
|
151578 |
|
|
|
151578 |
pwd="$(pwd)"
|
|
|
151578 |
datadir="$(cd ../../test-data/files && pwd)"
|
|
|
151578 |
@@ -66,7 +43,7 @@ port="$(awk 'BEGIN{srand(); print 65000+int(500*rand())}'
|
|
|
151578 |
|
|
|
151578 |
# Write an rsync daemon config file.
|
|
|
151578 |
cat > rsyncd.conf <
|
|
|
151578 |
-address = $listen_address
|
|
|
151578 |
+address = localhost
|
|
|
151578 |
port = $port
|
|
|
151578 |
pid file = $pwd/rsyncd.pid
|
|
|
151578 |
[src]
|
|
|
151578 |
@@ -90,6 +67,8 @@ function cleanup ()
|
|
|
151578 |
}
|
|
|
151578 |
trap cleanup INT TERM QUIT EXIT
|
|
|
151578 |
|
|
|
151578 |
+# XXX
|
|
|
151578 |
+ip=169.254.2.2
|
|
|
151578 |
user="$(id -un)"
|
|
|
151578 |
|
|
|
151578 |
guestfish --network -N test-rsync.img=fs -m /dev/sda1 <
|
|
|
151578 |
--
|
|
|
e9bfca |
2.17.1
|
|
|
151578 |
|