# mail -s "Subject Matter" chris@binnie.tld < /dev/null # mail -s "The one and only Billy Shears" chris@binnie.tld \ < file_full_of_lyrics # echo "The act you've known for all these years" | mail -s "Cellophane flowers of yellow and green" chris@binnie.tld # apt-get install heirloom-mailx # talk pepper # talk rita@ # mail -s "Filling in a ticket in her little white book" chris@binnie.tld < text_in_the_body # mail -s "Sitting on the sofa with a sister or two" chris@binnie.tld < bad_idea.jpg # apt-get install sharutils (cat EdgarAllenPoe.txt; uuencode ringo.jpg first.jpg; uuencode george.jpg second.jpg) | mail-s "Expert textpert choking smokers" chris@binnie.tld # touch {1..5}.jpg # ls *.jpg > file_list #!/bin/bash files="file_list" ( while read uniq; do ( uuencode $uniq new.$uniq ) done < $files; cat bodytxt) | mailx -s "Go to a show, you hope she goes" chris@binnie.tld exit chmod +x # mail -x "Not just anybody" -a 1.jpg chris@binnie.tld set smtp=smtps://smtp.gmail.com:465 set from="Chris Binnie" set smtp-auth-user=chris_binnie_linux set smtp-auth-password= set ssl-verify=ignore # mail -s "Made the bus in seconds flat" chris@binnie.tld -S ssl-verify=ignore -S smtp-auth-user=chris_binnie_linux < bodytxt # echo "Four thousand holes in Blackburn, Lancashire" | mail -r chris@linux.tld -v -s "Dragged a comb across my head" chris@binnie.tld # apt-get install ssmtp # The place where the mail goes. The actual machine name is required, no # MX records are consulted. Commonly mailhosts are named mail.domain.com mailhub=smtp.gmail.com:587 # The full hostname hostname=linux.chrisbinnie.tld # Are users allowed to set their own From: address? # YES - Allow the user to specify their own From: address # NO - Use the system generated From: address FromLineOverride=YES AuthUser=chris_binnie_linux@gmail.com AuthPass=my_plaintext_password UseTLS=YES UseSTARTTLS=YES AuthMethod=LOGIN # chown root:mail /etc/ssmtp/ssmtp.conf # chmod 640 /etc/ssmtp/ssmtp.conf # usermod -a -G mail chrisbinnie root:mail@cluster42.binnie.tld:external-sysadmins.smtp.tld ntp:stratum-1@ntp.binnie.tld:local-sysadmins.smtp.tld:2525 snort:security@binnie.tld:all-sysadmins.smtp.tld # ssmtp chris@binnie.tld To: chrisbinnie@linux.tld From: chris@binnie.tld Subject: Hello, Hello You say goodbye and I say hello -au -ap