mirror of
https://github.com/Dannecron/netology-devops.git
synced 2025-12-26 07:42:36 +03:00
add notes 04-yaml, move homework 4.1 to subdirectory
This commit is contained in:
14
src/homework/04-script/4.1/q3_script.sh
Executable file
14
src/homework/04-script/4.1/q3_script.sh
Executable file
@@ -0,0 +1,14 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
serverPort=80
|
||||
servers=("192.168.0.1" "173.194.222.113" "87.250.250.242")
|
||||
|
||||
for i in {1..5}
|
||||
do
|
||||
for server in ${servers[@]}
|
||||
do
|
||||
curl --connect-timeout 3 --max-time 5 http://${server}:${serverPort}
|
||||
curlResult=$?
|
||||
echo "$(date) curl result for ${server} is ${curlResult}" >> curl.log;
|
||||
done
|
||||
done
|
||||
Reference in New Issue
Block a user