make setting up apple mail clients easier by providing .mobileconfig device management profiles

including showing a qr code to easily get the file on iphones.
the profile is currently in the "account" page.

idea by x8x in issue #65
This commit is contained in:
Mechiel Lukkien
2023-09-23 12:05:40 +02:00
parent a0f3856e40
commit 2b97c21f99
20 changed files with 2076 additions and 148 deletions

View File

@ -1578,7 +1578,8 @@ func (Admin) DomainRemove(ctx context.Context, domain string) {
xcheckf(ctx, err, "removing domain")
}
// AccountAdd adds existing a new account, with an initial email address, and reloads the configuration.
// AccountAdd adds existing a new account, with an initial email address, and
// reloads the configuration.
func (Admin) AccountAdd(ctx context.Context, accountName, address string) {
err := mox.AccountAdd(ctx, accountName, address)
xcheckf(ctx, err, "adding account")
@ -1625,13 +1626,13 @@ func (Admin) SetAccountLimits(ctx context.Context, accountName string, maxOutgoi
xcheckf(ctx, err, "saving account limits")
}
// ClientConfigDomain returns configurations for email clients, IMAP and
// ClientConfigsDomain returns configurations for email clients, IMAP and
// Submission (SMTP) for the domain.
func (Admin) ClientConfigDomain(ctx context.Context, domain string) mox.ClientConfig {
func (Admin) ClientConfigsDomain(ctx context.Context, domain string) mox.ClientConfigs {
d, err := dns.ParseDomain(domain)
xcheckuserf(ctx, err, "parsing domain")
cc, err := mox.ClientConfigDomain(d)
cc, err := mox.ClientConfigsDomain(d)
xcheckf(ctx, err, "client config for domain")
return cc
}