If you have some other mailserver available, a tool like nullmailer can be helpful. It is a minimal solution, accepting mails from the local system and delegating the delivery to some smarter mailserver. The Debian wiki explains how to set it up. Basically, install the package and write account data for the smarter mailserver into a configuration file.

Ok, thanks Alexander, so I'm still in process of creating the mail server. I've had steps forward, but a couple back, as I updated systems at in opportune time and lost apache2. Working on that. I looked at the nullmailer install. I like the date on it: 2018. (Not too old, not too new.) Read the HOWTO to glean what I could.

The Debian postfix package comes with a good configuration assistant, which makes setting up a fully featured mail server quite easy. Again, see the Debian wiki, which also has details on all the bells and whistles you probably won't need.

Those were very helpful links. I'll repost this one: Installing_and_Configuring_Postfix_on_Debian.

Yes, I'm aware that you are using a Raspi. Guess which Linux distribution is the base for Raspbian a.k.a. Raspberry Pi OS.

Your comments made me realize that the problem space here was wall-to-wall debian. I'll go ahead and write this like we used to on usenet when the subject became implementation-specific:

[specific to debian implementations]

I had been unable to completely update my droplet until I found a bit of extra update syntax from ubuntu. I crammed it all into a new alias:

alias release='sudo apt-get update && sudo apt-get upgrade && apt-get dist-upgrade && sudo do-release-upgrade'

I had been in a limbo zone where I almost had 22.04 but now do:

root@fourth:~# release ... Checking for a new Ubuntu release There is no development version of an LTS available. To upgrade to the latest non-LTS development release set Prompt=normal in /etc/update-manager/release-upgrades. root@fourth:~# apt autoremove
Both nullmailer and postfix allow you to submit mails via SMTP, that's the traditional and cleanest way. Any "solution" that tries to automate interacting with some kind of webmailer will ultimately fail, simply because there is no standard, only guesswork. Postfix comes with a sendmail executable that emulates the original "sendmail" as much as needed to send mail. Nullmailer has nullmailer-inject, which is not as compatible, but accepts emails from STDIN like sendmail does, and accepts a few parameters like sendmail does.

Ok, and thanks for your comment. I'm happy to see your responses as I know they are likely to contain useful and exotic details of what is happening underneath the hood with unix. One issue I need to get clear is whether Digital Ocean is giving me port 25, so I will fire off this to them:

Dear Digital Ocean Support, I've been renting space from you for over a year now, and, because google will disallow 3rd-party use of their smtp server on May 30, am working up an email server with my DO site. I'm not entirely convinced that I have access to port 25, as it is blocked during the first 2 months. Do I? Thank you for your attention,

Beyond this, I got some partial results and hope to not need to start over. I think I got the MX record set up right with DO. I had to access the way back machine for some of my sources. This is from 5 years ago: way back machine on mx records.

Here's a nice, new fresh one: how-to-install-and-configure-postfix-on-ubuntu-22-04. I'll end up going through this again. Since the beginning of this write-up, I tore out and replaced apache2, changing Postfix twice, so I'll be due to go over it again.

One final thing. I told a friend that google was restricting 3rd-party access to their smtp server, and she asked me whether her iOS mail app that gets her gmail will still be able to do so. Does anyone have the expertise to speculate? (I hemmed and hawed.)


In reply to Re^2: emailing from one debian system to another by Aldebaran
in thread getting SMTP capability working by Aldebaran

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.