如何在MailGun上正确设置我的域名?

时间:2013-09-05 08:08:26

标签: email dns parse-platform mailgun

这可能是我唯一的问题。我在mailgun上的帐户中使用我的域名收到此消息:

Warning: Some of your domains (in red) have DNS configuration issues.

我该怎么办?我尝试了一个巨大的随机域名,它做了同样的事情。

感谢您一起来看看!

--------------------------如果这不是我唯一的问题------------- -------------------

我正在使用带有MailGun的parse.com。我已经设置了所有解析的东西,我已经使用MailGun创建了一个帐户,并使用MailGun添加了一个自定义域名。这是我的iOS代码:

    NSDictionary *params = [NSDictionary dictionaryWithObject:@"This is sent from your iPhone." forKey:@"text"];
    [PFCloud callFunctionInBackground:@"emailGrocery" withParameters:params block:^(id object, NSError *error)
    {
        if(!error)
        {
            NSLog(@"Succeeded");
        }
        else
        {
            NSString *errorMsg = [[error userInfo] objectForKey:@"error"];
            NSLog(@"%@", errorMsg);
        }
    }];

这是解析的一个例子。我认为这是应该做的,因为我在日志中收到了错误消息。

这是我的云代码:

 var Mailgun = require('mailgun');
 Mailgun.initialize('domain.com', 'key');

 Parse.Cloud.define("emailGrocery", function(request, response) {
 Mailgun.sendEmail({
   to: "myemail@gmail.com",
   from: "myemail@gmail.com",
   subject: "Hello from Cloud Code!",
   text: "Using Parse and Mailgun is great!"
 }, {
   success: function(httpResponse) {
     console.log(httpResponse);
     response.success("Email sent!");
   },
   error: function(httpResponse) {
     console.error(httpResponse);
     response.error("Uh oh, something went wrong");
   }
 });
});

我的实际电子邮件地址在那里作为发件人,另一个已知的电子邮件地址作为接收者。我总是得到错误回复。我有一个真正的域名和密钥。在我的自定义电子邮件域名下的mailgun帐户中,有以下消息:

Warning: Some of your domains (in red) have DNS configuration issues.

我无法弄清楚我应该怎么做。我意识到这可能是我唯一的问题,但我该怎么做才能解决这个问题?

3 个答案:

答案 0 :(得分:3)

我想分享2个屏幕截图,这些屏幕截图可能有助于在Namecheap中验证Mailgun的自定义域名...我将头撞在墙上2天:)

enter image description here

enter image description here

Mailgun有一个按钮检查你的DNS设置,有时它会给出假阴性,所以试试几次

答案 1 :(得分:2)

您需要使用SPF和DKIM验证您的域名。您可以通过添加TXT DNS记录来完成此操作。

查看更多信息 https://documentation.mailgun.com/user_manual.html#verifying-your-domain

答案 2 :(得分:1)

我在对自己进行故障排除时遇到了这个线程,并希望提供另一个主机的配置。我有一个关于VPS的网站,域名registar是主机。我在WHM中配置DNS。请参阅下面的示例:

This is the Mailgun page with the examples and check settings for the domain

This is the WHM DNS records