|
|
@@ -2,6 +2,8 @@ package setup
|
|
|
|
|
|
import (
|
|
|
"fmt"
|
|
|
+ "strings"
|
|
|
+
|
|
|
"github.com/Jinnrry/pmail/i18n"
|
|
|
"github.com/Jinnrry/pmail/services/auth"
|
|
|
"github.com/Jinnrry/pmail/utils/context"
|
|
|
@@ -27,6 +29,7 @@ func GetDNSSettings(ctx *context.Context) (map[string][]*DNSItem, error) {
|
|
|
|
|
|
for _, domain := range configData.Domains {
|
|
|
ret[domain] = []*DNSItem{
|
|
|
+ {Type: "A", Host: strings.ReplaceAll(configData.WebDomain, "."+configData.Domain, ""), Value: ip.GetIp(), TTL: 3600, Tips: i18n.GetText(ctx.Lang, "ip_taps")},
|
|
|
{Type: "A", Host: "smtp", Value: ip.GetIp(), TTL: 3600, Tips: i18n.GetText(ctx.Lang, "ip_taps")},
|
|
|
{Type: "A", Host: "pop", Value: ip.GetIp(), TTL: 3600, Tips: i18n.GetText(ctx.Lang, "ip_taps")},
|
|
|
{Type: "A", Host: "@", Value: ip.GetIp(), TTL: 3600, Tips: i18n.GetText(ctx.Lang, "ip_taps")},
|