Smtp email on boot



  • Is it possible to have an email sent using the smtp settings (system > advanced) when pfsense boots?



  • @charlie0440:

    Is it possible to have an email sent using the smtp settings (system > advanced) when pfsense boots?

    'booting' is one thing, pfSense should be able to connect to a mail server, which could be some where on the Internet.
    This means that interfaces should be up and functional.

    This is what I tried :
    Insert

    notify_all_remote(sprintf("pfSense booted."));
    

    just before the ending "?>" in this file : /etc/rc.bootup

    I received a mail saying "pfSense booted." when I rebooted pfSense..