Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
whats the easiest way to send text email to a specific addre
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
carbon
Guru
Guru


Joined: 27 Jun 2003
Posts: 455
Location: New York

PostPosted: Thu Jan 15, 2004 9:59 pm    Post subject: whats the easiest way to send text email to a specific addre Reply with quote

I am trying to find out how to send a email with a single command in the prompt. I was reading how to setup a postfix mail server, but that seems to overkilling. Is there a simple program that allows me to do the folllowing thing?

programName [text message] [address to send to]

or am I looking for something doesnt exist yet.
_________________
I do what I want, and that's what I do.
GNU World Domination

Carbon
Back to top
View user's profile Send private message
adaptr
Watchman
Watchman


Joined: 06 Oct 2002
Posts: 6730
Location: Rotterdam, Netherlands

PostPosted: Thu Jan 15, 2004 10:34 pm    Post subject: Reply with quote

You can do this with the standard "mail" program included in the "mailx" package.
All you need for it is a mail sender - ssmtp is included in Gentoo by default.
Code:
mail -s "your subject goes here" recipient@isp.tld < text_file

Couldn't be simpler, really.


Last edited by adaptr on Thu Jan 15, 2004 10:40 pm; edited 1 time in total
Back to top
View user's profile Send private message
carbon
Guru
Guru


Joined: 27 Jun 2003
Posts: 455
Location: New York

PostPosted: Thu Jan 15, 2004 10:38 pm    Post subject: Reply with quote

thanks, i will try that
_________________
I do what I want, and that's what I do.
GNU World Domination

Carbon
Back to top
View user's profile Send private message
adaptr
Watchman
Watchman


Joined: 06 Oct 2002
Posts: 6730
Location: Rotterdam, Netherlands

PostPosted: Thu Jan 15, 2004 10:41 pm    Post subject: Reply with quote

Note that I edited my post - didn't see that you had replied *already* ;-)
The mail program is in the mailx package:
Code:
emerge -pv mailx
Back to top
View user's profile Send private message
carbon
Guru
Guru


Joined: 27 Jun 2003
Posts: 455
Location: New York

PostPosted: Sat Jan 17, 2004 11:41 pm    Post subject: Reply with quote

mail -s "ip changed" bobbyjones@hotmail.com < "ip"

send-mail: warning: My hostname localhost is not a fully qualified name - set myhostname or mydomain in /etc/postfix/main.cf

postdrop: warning: My hostname localhost is not a fully qualified name - set myhostname or mydomain in /etc/postfix/main.cf


what does mailx have to do with postfix?
_________________
I do what I want, and that's what I do.
GNU World Domination

Carbon
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum