Home
Help
Search
Login
Register
OPNsense Forum
»
Archive
»
21.7 Legacy Series
»
Sending emails from scripts
« previous
next »
Print
Pages: [
1
]
Author
Topic: Sending emails from scripts (Read 2257 times)
jonm
Jr. Member
Posts: 51
Karma: 2
Sending emails from scripts
«
on:
February 16, 2022, 01:40:00 pm »
I have a requirement to send emails from various shell scripts. I've installed the postfix plugin but there's no commandline email client e.g. 'mail' to use in scripts. How do I install that? Apologies if this is a stupid question...
Logged
bartjsmit
Hero Member
Posts: 2018
Karma: 194
Re: Sending emails from scripts
«
Reply #1 on:
February 16, 2022, 01:50:30 pm »
OPNsense is mostly PHP according to Github.
https://github.com/opnsense/core
Have you tried its mail function?
https://www.w3schools.com/php/func_mail_mail.asp
Bart...
Logged
fabian
Hero Member
Posts: 2769
Karma: 200
OPNsense Contributor (Language, VPN, Proxy, etc.)
Re: Sending emails from scripts
«
Reply #2 on:
February 16, 2022, 06:40:25 pm »
This or postfix provides a tool as well.
Logged
jonm
Jr. Member
Posts: 51
Karma: 2
Re: Sending emails from scripts
«
Reply #3 on:
February 16, 2022, 08:29:37 pm »
Thanks, what's the postfix option please?
Logged
fabian
Hero Member
Posts: 2769
Karma: 200
OPNsense Contributor (Language, VPN, Proxy, etc.)
Re: Sending emails from scripts
«
Reply #4 on:
February 17, 2022, 07:20:59 pm »
There is no postfix solution, there are many. It is a full featured MTA (that can work in standalone mode, satellite mode,... ) and has utilities like sendmail.
Logged
Print
Pages: [
1
]
« previous
next »
OPNsense Forum
»
Archive
»
21.7 Legacy Series
»
Sending emails from scripts