Install a basic email server on Debian 13

Install the following packages:

aptitude install postfix

Postfix configuration

  • General mail configuration type: Internet Site
  • System mail name: your-domain.com
  • Recipient for root and postmaster mail: admin
  • Other destinations to accept mail for (blank for none): press enter
  • Local networks: press enter
  • Mailbox size limit (bytes): press enter
  • Local address extension character: press enter
  • Internet protocols to use: all

DNS configuration

Add the following records:

  • Type: A
  • Host: mail
  • Answer: server-ip
  • TTL: 300
  • Type: MX
  • Host: empty
  • Answer: mail.your-domain.com
  • TTL: 300
  • Prior: 10
  • Type: TXT
  • Host: empty
  • Answer: v=spf1 ip4:server-ip ~all
  • TTL: 3600