forked from third-party-mirrors/zfs_autobackup
test
This commit is contained in:
parent
3e243a0916
commit
0d26420b15
11
run_tests
11
run_tests
@ -1,12 +1,17 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ "$USER" != "root" ]; then
|
||||
echo "Need root to do proper zfs testing"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
#reactivate python environment, if any (usefull in Travis)
|
||||
source $VIRTUAL_ENV/bin/activate || true
|
||||
|
||||
# test needs ssh access to localhost for testing
|
||||
if ! [ -t ~/.ssh/id_rsa ]; then
|
||||
ssh-keygen -t rsa -f ~/.ssh/id_rsa -P '' || exit 1
|
||||
cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys || exit 1
|
||||
if ! [ -t /root/.ssh/id_rsa ]; then
|
||||
ssh-keygen -t rsa -f /root/.ssh/id_rsa -P '' || exit 1
|
||||
cat /root/.ssh/id_rsa.pub >> /root/.ssh/authorized_keys || exit 1
|
||||
ssh -oStrictHostKeyChecking=no localhost true || exit 1
|
||||
fi
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user