Curl to redo the request (Found 302)

The URL to download the Fedora 19 images is not persistent anymore,
they are now download from http://download.fedoraproject.org where the
request will be redirected to a different location. Passing the -L option
to the curl command will make it redo the request on the new place and
download the image correctly.

Related to bug #1199237

Change-Id: Ib9b9d65734992e2bf1a6888c5f2eb9de366f8204
This commit is contained in:
Lucas Alvares Gomes 2013-07-09 11:13:04 +01:00
parent 9a81644d65
commit 9f93451710

View file

@ -34,7 +34,7 @@ else
success="Downloaded and cached $url for the first time"
fi
rcode=$(curl -o $tmp -w '%{http_code}' $url $time_cond)
rcode=$(curl -L -o $tmp -w '%{http_code}' $url $time_cond)
if [ "$rcode" = "200" ] ; then
echo $success
mv $tmp $dest