From a767f28dd8faf2839339e4dca843aa28ee7ec71e Mon Sep 17 00:00:00 2001 From: Johannes Zellner Date: Wed, 29 Jun 2016 14:59:09 +0200 Subject: [PATCH] ensure the webadmin domain is correctly figured --- cloudron.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cloudron.js b/cloudron.js index f53ce31..210cad1 100644 --- a/cloudron.js +++ b/cloudron.js @@ -23,7 +23,7 @@ process.env.NODE_TLS_REJECT_UNAUTHORIZED = '0'; function Cloudron(box) { this._box = box; - this._isCustomDomain = box.domain === process.env.CUSTOM_DOMAIN; + this._isCustomDomain = box.domain === process.env.CUSTOM_DOMAIN || box.domain === process.env.SELFHOST_DOMAIN; this._adminFqdn = this._isCustomDomain ? 'my.' + box.domain : 'my-' + box.domain; this._origin = this._isCustomDomain ? 'https://my.' + box.domain : 'https://my-' + box.domain; @@ -652,7 +652,7 @@ Cloudron.prototype.checkMail = function (account, callback) { user: account.username, password: account.password, host: this._adminFqdn, - port: 993, // imap port + port: 993, // imap port tls: true, tlsOptions: { rejectUnauthorized: false }, readOnly: true