From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) by lore.proxmox.com (Postfix) with ESMTPS id B1B701FF191 for ; Tue, 21 Oct 2025 12:03:14 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 94D121A5EB; Tue, 21 Oct 2025 12:03:36 +0200 (CEST) From: Maximiliano Sandoval To: pve-devel@lists.proxmox.com Date: Tue, 21 Oct 2025 12:03:30 +0200 Message-ID: <20251021100332.251697-7-m.sandoval@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251021100332.251697-1-m.sandoval@proxmox.com> References: <20251021100332.251697-1-m.sandoval@proxmox.com> MIME-Version: 1.0 X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1761041006850 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.096 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment RCVD_IN_VALIDITY_CERTIFIED_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_RPBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_SAFE_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record URIBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [nodes.pm] Subject: [pve-devel] [PATCH manager 3/3] api: nodes: use new dc proxy option X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Proxmox VE development discussion Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: pve-devel-bounces@lists.proxmox.com Sender: "pve-devel" For the 'apl_download' and the 'query_url_metadata' API endpoints. Signed-off-by: Maximiliano Sandoval --- PVE/API2/Nodes.pm | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/PVE/API2/Nodes.pm b/PVE/API2/Nodes.pm index 4590b618..fde8229b 100644 --- a/PVE/API2/Nodes.pm +++ b/PVE/API2/Nodes.pm @@ -1750,7 +1750,8 @@ __PACKAGE__->register_method({ hash_required => 1, sha512sum => $appliance->{sha512sum}, md5sum => $appliance->{md5sum}, - http_proxy => $dccfg->{http_proxy}, + http_proxy => PVE::Cluster::get_proxy($dccfg, 'http', 'download'), + https_proxy => PVE::Cluster::get_proxy($dccfg, 'https', 'download'), }, ); }; @@ -1818,8 +1819,12 @@ __PACKAGE__->register_method({ $ua->agent("Proxmox VE"); my $dccfg = PVE::Cluster::cfs_read_file('datacenter.cfg'); - if ($dccfg->{http_proxy}) { - $ua->proxy(['http', 'https'], $dccfg->{http_proxy}); + if (my $http_proxy = PVE::Cluster::get_proxy($dccfg, 'http', 'download')) { + $ua->proxy('http', $http_proxy); + } + + if (my $https_proxy = PVE::Cluster::get_proxy($dccfg, 'https', 'download')) { + $ua->proxy('https', $https_proxy); } my $verify = $param->{'verify-certificates'} // 1; -- 2.47.3 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel