Skip to content
This repository was archived by the owner on Oct 19, 2022. It is now read-only.

Commit 06570ef

Browse files
committed
add restart test
Signed-off-by: Victor Vieux <[email protected]>
1 parent 02e50b3 commit 06570ef

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

.travis/integration.sh

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ PLUGIN_TAG=$TAG make enable
1414
# list plugins
1515
docker plugin ls
1616
# start sshd
17-
docker run -d -p 2222:22 sshd
17+
docker run -d --name sshd -p 2222:22 sshd
1818

1919
echo "# test1: simple"
2020
docker volume create -d vieux/sshfs:$TAG -o sshcmd=root@localhost:/ -o port=2222 -o password=root sshvolume
@@ -37,7 +37,14 @@ docker run --rm -v sshvolume:/read busybox grep -Fxq hello /read/world
3737
#cat /var/lib/docker/plugins/sshfs-state.json
3838
docker volume rm sshvolume
3939

40-
echo "# test4: source"
40+
echo "# test4: restart"
41+
docker volume create -d vieux/sshfs:$TAG -o sshcmd=root@localhost:/ -o port=2222 -o password=root sshvolume
42+
docker run --rm -v sshvolume:/write busybox sh -c "echo hello > /write/world"
43+
docker restart sshd
44+
docker run --rm -v sshvolume:/read busybox grep -Fxq hello /read/world
45+
docker volume rm sshvolume
46+
47+
echo "# test5: source"
4148
docker plugin disable vieux/sshfs:$TAG
4249
docker plugin set vieux/sshfs:$TAG state.source=/tmp
4350
docker plugin enable vieux/sshfs:$TAG
@@ -47,7 +54,7 @@ docker run --rm -v sshvolume:/read busybox grep -Fxq hello /read/world
4754
#cat /tmp/sshfs-state.json
4855
docker volume rm sshvolume
4956

50-
echo "# test5: ssh key"
57+
echo "# test6: ssh key"
5158
docker plugin disable vieux/sshfs:$TAG
5259
docker plugin set vieux/sshfs:$TAG sshkey.source=`pwd`/.travis/ssh/
5360
docker plugin enable vieux/sshfs:$TAG
@@ -56,3 +63,5 @@ docker run --rm -v sshvolume:/write busybox sh -c "echo hello > /write/world"
5663
docker run --rm -v sshvolume:/read busybox grep -Fxq hello /read/world
5764
#cat /var/lib/docker/plugins/sshfs-state.json
5865
docker volume rm sshvolume
66+
67+

0 commit comments

Comments
 (0)