Automatic tracking of changes for a web page with email notification

Εδώ θα βρείτε θέματα και λύσεις για τον διαγωνισμό εκπαιδευτικών του ΑΣΕΠ του έτους 2005, για την πληροφορική (ΠΕ19 & ΠΕ20)

I have created a script that helps me monitor a web page for specific changes and notify me when those changes have occurred! So if you want to monitor a web page for changes you can use this script in conjunction with a scheduled cron job which will periodically do the check.

# is the root shell (to gain root priviledges just type "sudo su -" at the command line

  1. Install mailx and postfix (instructions for debian/ubuntu)
  2. # apt-get install mailx postfix

  3. Setup postfix to be able to send mails
  4. You may be asked during installation about postfix configuration. If you are not asked or you already have postfix issue the following command:
    # dpkg-reconfigure postfix
    and select "Internet site".
    If you have more info about setting up postfix send me the link by mail.

  5. We create file urlwatch.
  6. You can get it here: urlwatch.sh
    or


  7. Μετά κάνουμε το αρχείο εκτελέσιμο.
  8. # chmod +x /etc/myscripts/urlwatch

  9. Then we create a link to /usr/bin, in order to be able to run the script from everywhere.
  10. # ln -s /etc/myscripts/urlwatch /usr/bin/

  11. Then you can run the script against a web page
  12. $ urlwatch kernel http://www.kernel.org/ kernel.html "new" "linus@linux.org,me@mymail.com"

Θέματα

Λύσεις