SpinTheMic
Pro

Interview practice question

Simple health-check script for a website

Cloud & DevOps · Linux and Scripting · Beginner

Write the logic for a script that checks every minute whether a website returns HTTP 200 and alerts if not.

What a strong answer covers

Your AI report card counts how many of these ideas you cover.

  • curl -s -o /dev/null -w "%{http_code}".
  • Compare with 200; timeout flag.
  • Alert via email/Slack webhook.
  • Run from cron/systemd timer.
  • Avoid alert spam (state file).
Practise this topic

Start without signing up. Sign in free to get an AI report card on your answer.

See all topics