Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Email in consolenebene
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Deutsches Forum (German)
View previous topic :: View next topic  
Author Message
cewlout
n00b
n00b


Joined: 18 Jul 2004
Posts: 45

PostPosted: Sun Jun 12, 2005 2:44 pm    Post subject: Email in consolenebene Reply with quote

Hallo Leute,

habe mal eine Frage bezüglich email in der Konsole. Ich habe hier nen Server, der alle zwei Wochen per cron automatisch ein sync macht und danach ein skript laufen lässt, dass ausgibt für welche ebuilds ein Update zur Verfügung steht und in ein log speichert.

Jetzt log ich mich alle zwei Wochen ein und schau mir das logfile an und entscheide dann, was ich updaten will und was nicht etc.. :)

Jetzt wäre es eine feine Sache, wenn mir dieses logfile nach Ablauf des Cronjobs einfach zu meinem EMailaccount senden würde (das ist aber ein Mailaccount, der nicht lokal irgendwie auf dem Server ist etc..)

Weiss jemand wie ich soetwas bewerkstelligen kann?

Nett wäre ein Programm, dass man per console starten kann und emails lossenden, es geht mir dabei eben rein um das Senden an meine "richtige" emailadresse, ich brauche da keinen "komplizierten" Client oder so.

Was muss ich installieren, wenn ich so eine funktionalität haben möchte?

Danke für euren Rat!


Grüße,

co
Back to top
View user's profile Send private message
psyqil
Advocate
Advocate


Joined: 26 May 2003
Posts: 2767

PostPosted: Sun Jun 12, 2005 2:48 pm    Post subject: Reply with quote

mail-mta/ssmtp müßtest Du schon haben, sonst ist mail-client/mailx auch gut für sowas.
Back to top
View user's profile Send private message
think4urs11
Bodhisattva
Bodhisattva


Joined: 25 Jun 2003
Posts: 6659
Location: above the cloud

PostPosted: Sun Jun 12, 2005 7:03 pm    Post subject: Reply with quote

net-mail/sendEmail wäre evtl. auch noch eine Alternative.
_________________
Nothing is secure / Security is always a trade-off with usability / Do not assume anything / Trust no-one, nothing / Paranoia is your friend / Think for yourself
Back to top
View user's profile Send private message
Anarcho
Advocate
Advocate


Joined: 06 Jun 2004
Posts: 2970
Location: Germany

PostPosted: Mon Jun 13, 2005 6:14 am    Post subject: Reply with quote

Wenn das ganze von Cron aufgerufen wird, lass das Script doch einfach die Ausgabe noch parallel an stdout ausgeben. Dann mailt dir Cron das automatisch zu. Musst nur ne Email-adresse im Crontab angeben, etwa so:

einfach in die erste Zeile der Crontab eintragen:
MAILTO="blah@blubb.de"

Natürlich muss dann auch ein MTA installiert sein (siehe oben)
_________________
...it's only Rock'n'Roll, but I like it!
Back to top
View user's profile Send private message
slick
Bodhisattva
Bodhisattva


Joined: 20 Apr 2003
Posts: 3495

PostPosted: Mon Jun 13, 2005 7:07 am    Post subject: Reply with quote

Ich mach sowas mit mutt
Code:
cat /path/logfile | mutt -x foo@example.com -s "Logfile `date`"

oder
Code:
mutt -x foo@example.com -s "Logfile `date`" -x /path/logfile

Als MTA habe ich Postfix laufen ...
Back to top
View user's profile Send private message
think4urs11
Bodhisattva
Bodhisattva


Joined: 25 Jun 2003
Posts: 6659
Location: above the cloud

PostPosted: Mon Jun 13, 2005 7:29 am    Post subject: Reply with quote

sendEmail benötigt z.B. keinerlei MTA oder sonstige Voraussetzungen (außer einem Perl Interpreter)
_________________
Nothing is secure / Security is always a trade-off with usability / Do not assume anything / Trust no-one, nothing / Paranoia is your friend / Think for yourself
Back to top
View user's profile Send private message
Anarcho
Advocate
Advocate


Joined: 06 Jun 2004
Posts: 2970
Location: Germany

PostPosted: Mon Jun 13, 2005 7:41 am    Post subject: Reply with quote

Verschickt sendEmail über einen SMTP-Server?
_________________
...it's only Rock'n'Roll, but I like it!
Back to top
View user's profile Send private message
think4urs11
Bodhisattva
Bodhisattva


Joined: 25 Jun 2003
Posts: 6659
Location: above the cloud

PostPosted: Mon Jun 13, 2005 7:51 am    Post subject: Reply with quote

Jepp
Quote:
About SendEmail
SendEmail is a lightweight, completly command line based, SMTP email agent. If you have the need to send email from a command prompt this tool is perfect. It was designed to be used in bash scripts, Perl programs, and web sites, but it is also quite useful in many other contexts. SendEmail is written in Perl and is unique in that it requires NO SPECIAL MODULES. It has a straight forward interface, making it very easy to use.
[This also works on Win32]

Als SMTP-Server kann jeder beliebige SMTP angegeben werden, ggf. mit Authentifizierung.
_________________
Nothing is secure / Security is always a trade-off with usability / Do not assume anything / Trust no-one, nothing / Paranoia is your friend / Think for yourself
Back to top
View user's profile Send private message
cewlout
n00b
n00b


Joined: 18 Jul 2004
Posts: 45

PostPosted: Mon Jun 13, 2005 8:22 am    Post subject: Reply with quote

Danke Leute für die Hilfe,

jetzt habe ich's per ssmtp und sendEmail hinbekommen und jetzt kann ich mich nicht entscheiden, was ich letztlich benutzen soll haha :). SCNR.
Im Ernst, funzt jetzt einwandfrei, danke wie immer!

Grüße
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Deutsches Forum (German) 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