Gitiles
Code Review
Sign In
gerrit.onosproject.org
/
onos
/
2786cefe0aafc7bfe49b104dbf25b4ae3edf1fc7
/
.
/
tools
/
test
/
scenarios
/
bin
/
curl-with-retry
blob: 7156cf7fa1ce70bcc742029c24cdfbe35ec7d873 [
file
] [
log
] [
blame
]
#!/bin/bash
aux
=/
tmp
/
stc
/
stc
-
$$
.
log
trap
"rm -f $aux 2>/dev/null"
EXIT
url
=
$1
echo curl
-
with
-
retry
:
$
*
for
i
in
{
1.
.
5
};
do
curl
-
f
-
isS
-
uonos
:
rocks $
{
url
}
>
$aux
if
[
$
?
=
0
];
then
cat $aux
exit
0
fi
sleep
1
done
cat $aux
exit
1