Skip to content

Commit 1cbde42

Browse files
committed
check if github.com and downloads.rclone.com are reachable
1 parent 9421d2a commit 1cbde42

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

Diff for: install.sh

+11
Original file line numberDiff line numberDiff line change
@@ -319,6 +319,11 @@ install_pwalk() {
319319

320320
echo -e "\nInstalling third-party dependency: pwalk... "
321321

322+
if ! curl -s --head https://github.com | grep "HTTP/2 200" > /dev/null; then
323+
echo "rclone downloads page https://downloads.rclone.org is not reachable. Please check your firewall settings."
324+
exit 1
325+
fi
326+
322327
# Variables of pwalk third-party tool froster is using
323328
pwalk_commit=1df438e9345487b9c51d1eea3c93611e9198f173 # update this commit when new pwalk version released
324329
pwalk_repository=https://github.com/fizwit/filesystem-reporting-tools/archive/${pwalk_commit}.tar.gz
@@ -357,6 +362,12 @@ install_rclone() {
357362

358363
echo -e "\nInstalling third-party dependency: rclone... "
359364

365+
if ! curl -s --head https://downloads.rclone.org | grep "HTTP/2 200" > /dev/null; then
366+
echo "rclone downloads page https://downloads.rclone.org is not reachable. Please check your firewall settings."
367+
exit 1
368+
fi
369+
370+
360371
# Check the architecture of the system
361372
arch=$(uname -m)
362373

0 commit comments

Comments
 (0)