From 7c51b8e6c98ea1c98b29f0c5c02459253b6831af Mon Sep 17 00:00:00 2001 From: Jan Winkler Date: Tue, 1 Aug 2023 17:18:07 +0200 Subject: [PATCH] security/acme: expose new values for TrueNAS deployhook, closes #3516 --- security/acme-client/pkg-descr | 1 + .../OPNsense/AcmeClient/forms/dialogAction.xml | 18 ++++++++++++++++++ .../AcmeClient/LeAutomation/AcmeProxmoxve.php | 3 +++ .../models/OPNsense/AcmeClient/AcmeClient.xml | 15 ++++++++++++++- 4 files changed, 36 insertions(+), 1 deletion(-) diff --git a/security/acme-client/pkg-descr b/security/acme-client/pkg-descr index 69c0bc07a..66d3fc589 100644 --- a/security/acme-client/pkg-descr +++ b/security/acme-client/pkg-descr @@ -13,6 +13,7 @@ Plugin Changelog Added: * add support for TrueNAS deployhook (#3421) * add support for Proxmox VE deployhook (#3422) +* add server,port and node name values for Proxmox VE deployhook (#3516) * add Google Domains DNS API 3.17 diff --git a/security/acme-client/src/opnsense/mvc/app/controllers/OPNsense/AcmeClient/forms/dialogAction.xml b/security/acme-client/src/opnsense/mvc/app/controllers/OPNsense/AcmeClient/forms/dialogAction.xml index 58d92f24c..905f1d49f 100644 --- a/security/acme-client/src/opnsense/mvc/app/controllers/OPNsense/AcmeClient/forms/dialogAction.xml +++ b/security/acme-client/src/opnsense/mvc/app/controllers/OPNsense/AcmeClient/forms/dialogAction.xml @@ -294,6 +294,24 @@ text The user who owns the API key. Defaults to root. + + action.acme_proxmoxve_server + + text + The hostname of the proxmox ve node. + + + action.acme_proxmoxve_port + + text + The port number the management interface is on. Defaults to 8006. + + + action.acme_proxmoxve_nodename + + text + The name of the node we will be connecting to. + action.acme_proxmoxve_realm diff --git a/security/acme-client/src/opnsense/mvc/app/library/OPNsense/AcmeClient/LeAutomation/AcmeProxmoxve.php b/security/acme-client/src/opnsense/mvc/app/library/OPNsense/AcmeClient/LeAutomation/AcmeProxmoxve.php index 6e4c8e16f..4ac4ba46e 100644 --- a/security/acme-client/src/opnsense/mvc/app/library/OPNsense/AcmeClient/LeAutomation/AcmeProxmoxve.php +++ b/security/acme-client/src/opnsense/mvc/app/library/OPNsense/AcmeClient/LeAutomation/AcmeProxmoxve.php @@ -39,6 +39,9 @@ class AcmeProxmoxve extends Base implements LeAutomationInterface public function prepare() { $this->acme_env['DEPLOY_PROXMOXVE_USER'] = (string)$this->config->acme_proxmoxve_user; + $this->acme_env['DEPLOY_PROXMOXVE_SERVER'] = (string)$this->config->acme_proxmoxve_server; + $this->acme_env['DEPLOY_PROXMOXVE_SERVER_PORT'] = (string)$this->config->acme_proxmoxve_port; + $this->acme_env['DEPLOY_PROXMOXVE_NODE_NAME'] = (string)$this->config->acme_proxmoxve_nodename; $this->acme_env['DEPLOY_PROXMOXVE_USER_REALM'] = (string)$this->config->acme_proxmoxve_realm; $this->acme_env['DEPLOY_PROXMOXVE_API_TOKEN_NAME'] = (string)$this->config->acme_proxmoxve_tokenid; $this->acme_env['DEPLOY_PROXMOXVE_API_TOKEN_KEY'] = (string)$this->config->acme_proxmoxve_tokenkey; diff --git a/security/acme-client/src/opnsense/mvc/app/models/OPNsense/AcmeClient/AcmeClient.xml b/security/acme-client/src/opnsense/mvc/app/models/OPNsense/AcmeClient/AcmeClient.xml index ec0d1273f..fd315ba4d 100644 --- a/security/acme-client/src/opnsense/mvc/app/models/OPNsense/AcmeClient/AcmeClient.xml +++ b/security/acme-client/src/opnsense/mvc/app/models/OPNsense/AcmeClient/AcmeClient.xml @@ -1395,10 +1395,23 @@ /^.{1,1024}$/u Should be a string between 1 and 1024 characters. + + N + /^.{1,1024}$/u + Should be a string between 1 and 1024 characters. + + + 8006 + N + + + N + /^.{1,1024}$/u + Should be a string between 1 and 1024 characters. + pam N - N /^.{1,1024}$/u Should be a string between 1 and 1024 characters.