for the last few days I have been trying to run an email server and it looks like I finally made it.
The email server runs on Debian in combination with postfix and dovecot. Webmin is also installed, in which I see emails for an user and I can also send emails.
I created a test user "Kontakt" and here is a screenshot from the webmin SCREENSHOT
Next I installed roundcube, configured and tested the smtp and imap connection. Everything is fine, but after logging in to the roundcube I do not see any emails.
I found that emails are stored in /var/spool/kontakt, but not in maildir and I do not why.
Summary - My goal is to be able to write, read and manage emails via a roundcube.
QUESTION 2: How can I ensure that an email address can only have a domain name, not a hostname?
For example, if I send an email from gmail to [email protected], the email is ok. But if I send an email to [email protected], I will receive a message back that the email could not be delivered.
Thank you very much
<[email protected]>: User unknown in virtual alias table
postconf: warning: /etc/postfix/master.cf: undefined parameter: mua_sender_restrictions
postconf: warning: /etc/postfix/master.cf: undefined parameter: mua_helo_restrictions
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
allow_min_user = yes
append_dot_mydomain = no
biff = no
compatibility_level = 2
home_mailbox = Maildir/
inet_interfaces = all
inet_protocols = ipv4
mailbox_command = procmail -a "$EXTENSION"
mailbox_size_limit = 0
mydestination = $myhostname, xxxxxx.contaboserver.net, localhost.contaboserver.net, , localhost
mydomain = mintiga.cz
myhostname = mail.mintiga.cz
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
myorigin = $mydomain
queue_directory = /var/spool/postfix
readme_directory = no
recipient_delimiter = +
relayhost =
smtp_tls_loglevel = 1
smtp_tls_note_starttls_offer = yes
smtp_tls_security_level = may
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
smtp_use_tls = yes
smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU)
smtpd_recipient_restrictions = permit_mynetworks,permit_auth_destination,permit_sasl_authenticated,reject
smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated defer_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_path = private/auth
smtpd_sasl_security_options = noanonymous
smtpd_sasl_type = dovecot
smtpd_tls_cert_file = /etc/letsencrypt/live/mail.mintiga.cz/fullchain.pem
smtpd_tls_key_file = /etc/letsencrypt/live/mail.mintiga.cz/privkey.pem
smtpd_tls_loglevel = 1
smtpd_tls_received_header = yes
smtpd_tls_security_level = may
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtpd_use_tls = yes
virtual_alias_domains = $mydomain
virtual_alias_maps = hash:/etc/postfix/virtual
postconf: warning: /etc/postfix/main.cf: unused parameter: smtpd_sasl_location_domain=$myhostname
# 2.2.27 (): /etc/dovecot/dovecot.conf
# Pigeonhole version 0.4.16 ()
# OS: Linux 4.9.0-15-amd64 x86_64 Debian 9.13
auth_debug = yes
auth_debug_passwords = yes
auth_mechanisms = plain login
auth_verbose = yes
disable_plaintext_auth = no
mail_debug = yes
mail_location = maildir:~/Maildir
namespace inbox {
inbox = yes
location =
mailbox Drafts {
auto = subscribe
special_use = \Drafts
}
mailbox Junk {
auto = subscribe
special_use = \Junk
}
mailbox Sent {
auto = subscribe
special_use = \Sent
}
mailbox "Sent Messages" {
special_use = \Sent
}
mailbox Trash {
auto = subscribe
special_use = \Trash
}
prefix =
separator = .
type = private
}
passdb {
driver = pam
}
protocols = " imap pop3"
service auth {
unix_listener /var/spool/postfix/private/auth {
group = postfix
mode = 0666
user = postfix
}
}
service imap-login {
inet_listener imap {
port = 143
}
inet_listener imaps {
port = 993
ssl = yes
}
}
ssl = required
ssl_cert = </etc/letsencrypt/live/mail.mintiga.cz/fullchain.pem
ssl_key = # hidden, use -P to show it
userdb {
driver = passwd
}