Mail-in-a-Box is an open source software package that can easily convert your Ubuntu server into a full-stack email solution for multiple domains.
To protect the server, Mail-in-a-Box uses Fail2ban and SSL certificate (self-signed by default). It will automatically configure the UFW firewall and open all necessary ports. Its anti-spam and other security features include greylisting, SPF, DKIM, DMARC, opportunistic TLS, strong ciphers, HSTS and DNSSEC (with DANE TLSA).
Vps Machine Requirements :-
- 2 VCPU
- 2 GB of RAM
- 80 GB storage
- Ubuntu 20.04|18.04
Popular VPS provider with Open port 25
First, preparations
Prepare a domain name and prepare the NS1 and NS2 A records to point to the server IP address for DNS purposes.
ns1.box.vkttech.com
ns2.box.vkttech.com
- Now, find the page where you can set up glue records. Then, add these entries, replacing 205.0.115.2 with the IP address of your server:
ns1.box.vkttech.com 205.0.115.2
ns2.box.vkttech.com 205.0.115.2
Set The Hostname
hostnamectl set-hostname box.vkttech.com
Upgrade system source
apt update && apt upgrade -y
Second, install Mail-in-a-Box
- 1.Install one-click script
curl -s https://mailinabox.email/setup.sh | sudo bash
2.Set up the mail system
Here we need to set up a system post office, we can be a custom domain name.
- 3.Determine the host name
4.Choose the time zone we need, such as US, then press ENTER, and then wait for a while, anyway, they are installed automatically.
5.Set Account Password
Finally set the account password, and then press Enter to see the installation is complete.
Log in to the mailbox dashboard
Now you will log in to the management interface of Mail-in-a-Box and learn about your new email server. To access the management interface, use the URL provided in the post-installation output. it should be:
https://box.vkttech.com/admin
In the top-left menu you’ll notice an element called System. Click on it and then select TLS (SSL) Certificates. Now click on the blue button that says Provision and within a few minutes the certificate status should change to Signed & valid.
Add New Users
You can easily add domains and other email addresses to the Mail-in-a-Box server. To add a new address in a new or existing domain, just add another email account in ” Mail”> “Users” in the management dashboard . If the email address is in a new domain, “Mailbox” will automatically add appropriate new settings for it.
Smtp Server Details.
Use the following settings when you set up your email on your phone, desktop, or other device:
Access Webmail and send a test email
To access the Webmail interface, click ” Mail”> “Description ” in the top navigation bar , and then visit the URL provided on that page. It should look like this:
https://box.vkttech.com/mail
To view the current DNS settings, please visit System>External DNS . To add your own entry, please visit System>Custom DNS .
Mail-in-a-Box also provides functions beyond the scope of this article. It can be provided by ownCloud as a hosted contact and calendar manager. It can also be used to host static websites.