Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Bookmarks
  • Search
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Cloudron Forum

Apps | Demo | Docs | Install
  1. Cloudron Forum
  2. Discuss
  3. Cloudron email Server - multiple domains

Cloudron email Server - multiple domains

Scheduled Pinned Locked Moved Discuss
emailemail server
19 Posts 6 Posters 2.1k Views 6 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • KubernetesK Kubernetes

    I did a test and created a fresh mailbox on my cloudron for one of my existing domains to check the headers when sending an e-mail. Here is the header result:

    Authentication-Results: RECEIVERMAILSERVERHOSTNAME (dis=neutral; info=dmarc domain policy);
    	dmarc=pass (dis=neutral p=reject; aspf=r; adkim=r; pSrc=dns) header.from=IDEA.COM;
    	dkim=pass header.d=IDEA.COM header.s=cloudron-2f6807 header.b=F+cRmQ1r
    Received: from RECEIVERMAILSERVERHOSTNAME ([fd:ac:0:0:0:0:e:13])
            by RECEIVERMAILSERVERHOSTNAME
            with SMTP (SubEthaSMTP 3.1.7) id M4CRBUTJ
            for RECEIPIENT@SOMEWHERE.COM;
            Fri, 06 Dec 2024 14:04:18 +0100 (CET)
    Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=IP_OF_CLOUDRON_SERVER; helo=MY.EXAMPLE.COM; envelope-from=SENDER@IDEA.COM; receiver=SOMEWHERE.COM 
    Received: from MY.EXAMPLE.COM (MY.EXAMPLE.COM [XX.XX.XX.XX])
    	by RECEIVERMAILSERVERHOSTNAME (Postfix) with ESMTPS id 35F3543CDFB8
    	for <SOMEONE@SOMEWHERE.COM>; Fri,  6 Dec 2024 14:04:18 +0100 (CET)
    Received: (Haraka outbound); Fri, 06 Dec 2024 13:04:17 +0000
    Authentication-Results: MY.EXAMPLE.COM;
    	auth=pass (plain)
    From: "test user" <SENER@IDEA.COM>
    To: "SOMEONE@SOMEWHERE.COM" <SOMEONE@SOMEWHERE.COM>
    Subject: test email
    Date: Fri, 06 Dec 2024 13:04:17 +0000
    Message-Id: <em10edd919-xxxx-4789-xxxx-db21f7b92ff5@584dbbfc.com>
    Reply-To: "test user" <SOMEONE@SOMEWHERE.COM>
    User-Agent: mailClient/10.1.4828.0
    MIME-Version: 1.0
    Content-Type: text/plain; charset=utf-8; format=flowed
    Content-Transfer-Encoding: quoted-printable
    DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple;
    	d=IDEA.COM; s=cloudron-12345;
    	h=from:reply-to:subject:date:message-id:to:mime-version;
    	bh=7Yyzn....*
    

    So at least for the sending server hostname the my.example.com domain will leak.

    humptydumptyH Offline
    humptydumptyH Offline
    humptydumpty
    wrote on last edited by humptydumpty
    #5

    @Kubernetes Spot on. This has been my set up since I hopped on board with Cloudron. The mail server is shown in the headers when sending from other domains. @LoudLemur I have my @domain.com, @domain1.com, @domain2.com emails forwarded to my idea.com mailbox to centralize it all. Works well! The only drawback is that on iOS using the native mail app, you can't reply using the original receiver address (@domain.com). You would need to link each mailbox individually in iOS (no alias support) for that. Otherwise, just checking all your mail in one inbox is possible. You can add the aliases in roundcube/snappy on the web ui and use that if needed.

    As for having multiple MX records/providers, I have limited experience with that. Off the top of my head, I think it's possible since Stripe did require me to add some records to have my domain show up instead of theirs when creating invoices directly from their platform. I'll need to check how I have it all set up again.

    1 Reply Last reply
    1
    • humptydumptyH Offline
      humptydumptyH Offline
      humptydumpty
      wrote on last edited by
      #6

      @LoudLemur The Stripe records I have are TXT and CNAME records, not MX records.

      1 Reply Last reply
      0
      • C Offline
        C Offline
        crazybrad
        wrote on last edited by
        #7

        What if you configured other domains to send mail via an SMTP service like Postmark? Probably the server IP address would leak, but perhaps not the domain.

        1 Reply Last reply
        0
        • humptydumptyH Offline
          humptydumptyH Offline
          humptydumpty
          wrote on last edited by humptydumpty
          #8

          I use mailgun smtp. The mail server domain is visible in the email header. Also, I have two other cloudrons pointing to the main Cloudron mail server. This setup has been working flawlessly.

          1 Reply Last reply
          1
          • C Offline
            C Offline
            crazybrad
            wrote on last edited by
            #9

            @humptydumpty Thanks for saving me some testing time.

            1 Reply Last reply
            3
            • robiR Offline
              robiR Offline
              robi
              wrote on last edited by
              #10

              FYI: There is another local sending IP leak that happens with most mobile/desktop clients but not web clients, like snappy.

              So keep that in mind if you don't care to have your current local IP be sent in plain text via the email headers.

              Conscious tech

              humptydumptyH 1 Reply Last reply
              2
              • robiR robi

                FYI: There is another local sending IP leak that happens with most mobile/desktop clients but not web clients, like snappy.

                So keep that in mind if you don't care to have your current local IP be sent in plain text via the email headers.

                humptydumptyH Offline
                humptydumptyH Offline
                humptydumpty
                wrote on last edited by
                #11

                @robi another reason to use a VPN!

                robiR 1 Reply Last reply
                0
                • humptydumptyH humptydumpty

                  @robi another reason to use a VPN!

                  robiR Offline
                  robiR Offline
                  robi
                  wrote on last edited by
                  #12

                  @humptydumpty it may not help as the email client doesn't care what your VPN interface is, only the local native interface. Always validate, even then, safer to use the web interface of the sending SMTP server.

                  Conscious tech

                  humptydumptyH 1 Reply Last reply
                  0
                  • robiR robi

                    @humptydumpty it may not help as the email client doesn't care what your VPN interface is, only the local native interface. Always validate, even then, safer to use the web interface of the sending SMTP server.

                    humptydumptyH Offline
                    humptydumptyH Offline
                    humptydumpty
                    wrote on last edited by
                    #13

                    @robi said in Cloudron email Server - multiple domains:

                    local native interface.

                    Just to make sure i understood you correctly, you’re referring to the ipv4 address that i get from my ISP, right?

                    If so, how can an app sneak behind my VPN client?

                    robiR 1 Reply Last reply
                    1
                    • humptydumptyH humptydumpty

                      @robi said in Cloudron email Server - multiple domains:

                      local native interface.

                      Just to make sure i understood you correctly, you’re referring to the ipv4 address that i get from my ISP, right?

                      If so, how can an app sneak behind my VPN client?

                      robiR Offline
                      robiR Offline
                      robi
                      wrote on last edited by
                      #14

                      @humptydumpty Yes.

                      It's not that it sneaks behind or doesn't use your VPN, it's that is has access to your actual IP when the headers are generated before it sends it over the VPN.

                      Last time I tried there was no way to configure the client to avoid that. Hard coded.

                      Conscious tech

                      1 Reply Last reply
                      3
                      • fbartelsF Offline
                        fbartelsF Offline
                        fbartels
                        App Dev
                        wrote on last edited by
                        #15

                        Yes, every server that the mail passes through gets documented with a received header in the message.

                        https://www.thesslstore.com/blog/how-to-read-an-email-header/

                        The client can not influence this, but the mail server could remove this information. https://serverfault.com/questions/413533/remove-hide-client-sender-ip-from-postfix

                        1 Reply Last reply
                        0
                        • L Offline
                          L Offline
                          LoudLemur
                          wrote on last edited by LoudLemur
                          #16

                          I really am amazed at you all. You are quite awesome in your ability to keep these complexities clear in your mind. I find it difficult to even phrase the issues let alone understand them.

                          Let me try this and hopefully somebody will be able to help me:

                          There is one server over there (not a Cloudron) doing its own thing, but without individual mailboxes for people, because of the costs. Lets call it cheapo.com

                          Purely (initially anyway) to help solve cheapo's lack of emails problem, we have this idea: setup a new server on a completely different VPS, a cloudron, on a sub-domain of cheapo.com, for example mail.cheapo.com

                          Would we be able to do that? Once it was up and running, then setup snappy and give everybody in cheapo.com email addresses? e.g.

                          alice@cheapo.com
                          bob@cheapo.com
                          charlie@cheapo.com

                          or would the email addresses need to have some "ugly" appearance, like:
                          alice@mail.cheapo.com
                          or something like that.

                          1 Reply Last reply
                          0
                          • humptydumptyH Offline
                            humptydumptyH Offline
                            humptydumpty
                            wrote on last edited by humptydumpty
                            #17

                            No ugly. Set up the Cloudron. Use mail.cheapo.com as the mail server. Add the domain cheapo.com in CR dash under domains. Create mailboxes like Alice@cheapo.com and have folks access it through snappy.

                            If manual dns, don’t forget to set up records for spf, dkim, and dmarc.

                            L 1 Reply Last reply
                            1
                            • humptydumptyH humptydumpty

                              No ugly. Set up the Cloudron. Use mail.cheapo.com as the mail server. Add the domain cheapo.com in CR dash under domains. Create mailboxes like Alice@cheapo.com and have folks access it through snappy.

                              If manual dns, don’t forget to set up records for spf, dkim, and dmarc.

                              L Offline
                              L Offline
                              LoudLemur
                              wrote on last edited by LoudLemur
                              #18

                              @humptydumpty said in Cloudron email Server - multiple domains:

                              No ugly. Set up the Cloudron. Use mail.cheapo.com as the mail server. Add the domain cheapo.com in CR dash under domains. Create mailboxes like Alice@cheapo.com and have folks access it through snappy.

                              If manual dns, don’t forget to set up records for spf, dkim, and dmarc.

                              Hey, thank you! Would it matter what domain was used for the registration of the cloudron in this case? For example, could I setup the cloudron with the name e.g. anythingwilldo.com (rather than as I had originally suggested using a subdomain of cheapo.com), register that with cloudron.io and then do the important part of configuring the mail server for anythingwilldo.com to be (in this case) mail.cheapo.com and in the cloudron dashboard add cheapo.com as domain?

                              humptydumptyH 1 Reply Last reply
                              0
                              • L LoudLemur

                                @humptydumpty said in Cloudron email Server - multiple domains:

                                No ugly. Set up the Cloudron. Use mail.cheapo.com as the mail server. Add the domain cheapo.com in CR dash under domains. Create mailboxes like Alice@cheapo.com and have folks access it through snappy.

                                If manual dns, don’t forget to set up records for spf, dkim, and dmarc.

                                Hey, thank you! Would it matter what domain was used for the registration of the cloudron in this case? For example, could I setup the cloudron with the name e.g. anythingwilldo.com (rather than as I had originally suggested using a subdomain of cheapo.com), register that with cloudron.io and then do the important part of configuring the mail server for anythingwilldo.com to be (in this case) mail.cheapo.com and in the cloudron dashboard add cheapo.com as domain?

                                humptydumptyH Offline
                                humptydumptyH Offline
                                humptydumpty
                                wrote on last edited by humptydumpty
                                #19

                                @LoudLemur You could do that. No problem. You can specify the mail server location to be any SUB and pick any of the domains you have set up in Cloudron. To make things even wackier, you could use multiple subdomains like sub.sub.domain.com as the mail server.

                                1 Reply Last reply
                                1
                                Reply
                                • Reply as topic
                                Log in to reply
                                • Oldest to Newest
                                • Newest to Oldest
                                • Most Votes


                                • Login

                                • Don't have an account? Register

                                • Login or register to search.
                                • First post
                                  Last post
                                0
                                • Categories
                                • Recent
                                • Tags
                                • Popular
                                • Bookmarks
                                • Search