all lists on lists.proxmox.com
 help / color / mirror / Atom feed
From: Michal Fox <me@dualfroz.com>
To: pve-devel@lists.proxmox.com
Subject: [PATCH widget-toolkit 2/2] acme: domain edit: allow setting the alias of DNS domains
Date: Sun,  4 Oct 2026 11:58:09 +0000	[thread overview]
Message-ID: <20261004115809.7-3-me@dualfroz.com> (raw)
In-Reply-To: <20261004115809.7-1-me@dualfroz.com>

Domains validated with the DNS challenge can have an alias, so that the
challenge record is created on another domain, which the
'_acme-challenge' record of the domain points to with a CNAME.

But the alias could only be set on the CLI, as the edit window only
kept an existing one in a hidden field. Show it as a text field for
domains with the DNS challenge type, like the plugin.

As a side effect, an existing alias is not kept anymore when switching
a domain to the HTTP challenge type with separate domain entries, like
it is done in Proxmox Mail Gateway, where it has no meaning.

Signed-off-by: Michal Fox <me@dualfroz.com>
---
Tested in the browser the same way as the PVE window, both with the
'domains' list (PBS) and with separate domain entries and usage (PMG).

 src/window/ACMEDomains.js | 20 +++++++++++++-------
 1 file changed, 13 insertions(+), 7 deletions(-)

diff --git a/src/window/ACMEDomains.js b/src/window/ACMEDomains.js
index a2d2f83..029d427 100644
--- a/src/window/ACMEDomains.js
+++ b/src/window/ACMEDomains.js
@@ -142,16 +142,14 @@ Ext.define('Proxmox.window.ACMEDomainEdit', {
                         change: function (cb, value) {
                             let me = this;
                             let view = me.up('pmxACMEDomainEdit');
-                            let pluginField = view.down('field[name=plugin]');
-                            pluginField.setDisabled(value !== 'dns');
-                            pluginField.setHidden(value !== 'dns');
+                            for (const name of ['plugin', 'alias']) {
+                                let field = view.down(`field[name=${name}]`);
+                                field.setDisabled(value !== 'dns');
+                                field.setHidden(value !== 'dns');
+                            }
                         },
                     },
                 },
-                {
-                    xtype: 'hidden',
-                    name: 'alias',
-                },
                 {
                     xtype: 'pmxACMEPluginSelector',
                     name: 'plugin',
@@ -170,6 +168,14 @@ Ext.define('Proxmox.window.ACMEDomainEdit', {
                     value: '',
                     fieldLabel: gettext('Domain'),
                 },
+                {
+                    xtype: 'proxmoxtextfield',
+                    name: 'alias',
+                    disabled: true,
+                    hidden: true,
+                    fieldLabel: gettext('Alias'),
+                    emptyText: Proxmox.Utils.noneText,
+                },
                 {
                     xtype: 'combobox',
                     name: 'usage',
-- 
2.43.0




      parent reply	other threads:[~2026-10-04 11:58 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-04 11:58 [PATCH manager/widget-toolkit 0/2] fix #4588: acme: allow setting the alias of DNS domains Michal Fox
2026-10-04 11:58 ` [PATCH manager 1/2] fix #4588: ui: " Michal Fox
2026-10-04 11:58 ` Michal Fox [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261004115809.7-3-me@dualfroz.com \
    --to=me@dualfroz.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal