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 0C0E11FF13B for ; Tue, 13 Jan 2026 14:46:14 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 31DEC185F3; Tue, 13 Jan 2026 14:46:17 +0100 (CET) Date: Tue, 13 Jan 2026 14:45:40 +0100 From: Fabian =?iso-8859-1?q?Gr=FCnbichler?= To: Proxmox Backup Server development discussion References: <20260108112629.189670-1-s.rufinatscha@proxmox.com> <20260108112629.189670-7-s.rufinatscha@proxmox.com> In-Reply-To: <20260108112629.189670-7-s.rufinatscha@proxmox.com> MIME-Version: 1.0 User-Agent: astroid/0.17.0 (https://github.com/astroidmail/astroid) Message-Id: <1768309161.9y1q4pzth1.astroid@yuna.none> X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1768311899244 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.046 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 SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Subject: Re: [pbs-devel] [PATCH proxmox-backup v5 2/5] acme: include proxmox-acme-api dependency X-BeenThere: pbs-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox Backup Server development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Proxmox Backup Server development discussion Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: pbs-devel-bounces@lists.proxmox.com Sender: "pbs-devel" On January 8, 2026 12:26 pm, Samuel Rufinatscha wrote: > PBS currently uses its own ACME client and API logic, while PDM uses the > factored out proxmox-acme and proxmox-acme-api crates. This duplication > risks differences in behaviour and requires ACME maintenance in two > places. This patch is part of a series to move PBS over to the shared > ACME stack. this doesn't need to be in nearly every commit here. adding the dependency and initializing things without using them also has no stand-alone value, so this doesn't need to be its own commit. we could have two commits: - add proxmox-acme-api and use it for client and API - remove src/acme since it is now unused or three or more if you want to split out some of the API replacement where there isn't a 1:1 relation between old and new code.. > > Changes: > - Add proxmox-acme-api with the "impl" feature as a dependency. > - Initialize proxmox_acme_api in proxmox-backup- api, manager and proxy. > * Inits PBS config dir /acme as proxmox ACME directory > > Signed-off-by: Samuel Rufinatscha > --- > Cargo.toml | 3 +++ > src/bin/proxmox-backup-api.rs | 2 ++ > src/bin/proxmox-backup-manager.rs | 2 ++ > src/bin/proxmox-backup-proxy.rs | 1 + > 4 files changed, 8 insertions(+) > > diff --git a/Cargo.toml b/Cargo.toml > index 1aa57ae5..feae351d 100644 > --- a/Cargo.toml > +++ b/Cargo.toml > @@ -101,6 +101,7 @@ pbs-api-types = "1.0.8" > # other proxmox crates > pathpatterns = "1" > proxmox-acme = "1" > +proxmox-acme-api = { version = "1", features = [ "impl" ] } > pxar = "1" > > # PBS workspace > @@ -251,6 +252,7 @@ pbs-api-types.workspace = true > > # in their respective repo > proxmox-acme.workspace = true > +proxmox-acme-api.workspace = true > pxar.workspace = true > > # proxmox-backup workspace/internal crates > @@ -269,6 +271,7 @@ proxmox-rrd-api-types.workspace = true > [patch.crates-io] > #pbs-api-types = { path = "../proxmox/pbs-api-types" } > #proxmox-acme = { path = "../proxmox/proxmox-acme" } > +#proxmox-acme-api = { path = "../proxmox/proxmox-acme-api" } > #proxmox-api-macro = { path = "../proxmox/proxmox-api-macro" } > #proxmox-apt = { path = "../proxmox/proxmox-apt" } > #proxmox-apt-api-types = { path = "../proxmox/proxmox-apt-api-types" } > diff --git a/src/bin/proxmox-backup-api.rs b/src/bin/proxmox-backup-api.rs > index 417e9e97..d0091dca 100644 > --- a/src/bin/proxmox-backup-api.rs > +++ b/src/bin/proxmox-backup-api.rs > @@ -14,6 +14,7 @@ use proxmox_rest_server::{ApiConfig, RestServer}; > use proxmox_router::RpcEnvironmentType; > use proxmox_sys::fs::CreateOptions; > > +use pbs_buildcfg::configdir; > use proxmox_backup::auth_helpers::*; > use proxmox_backup::config; > use proxmox_backup::server::auth::check_pbs_auth; > @@ -78,6 +79,7 @@ async fn run() -> Result<(), Error> { > let mut command_sock = proxmox_daemon::command_socket::CommandSocket::new(backup_user.gid); > > proxmox_product_config::init(backup_user.clone(), pbs_config::priv_user()?); > + proxmox_acme_api::init(configdir!("/acme"), true)?; > > let dir_opts = CreateOptions::new() > .owner(backup_user.uid) > diff --git a/src/bin/proxmox-backup-manager.rs b/src/bin/proxmox-backup-manager.rs > index f8365070..30bc8da9 100644 > --- a/src/bin/proxmox-backup-manager.rs > +++ b/src/bin/proxmox-backup-manager.rs > @@ -19,6 +19,7 @@ use proxmox_router::{cli::*, RpcEnvironment}; > use proxmox_schema::api; > use proxmox_sys::fs::CreateOptions; > > +use pbs_buildcfg::configdir; > use pbs_client::{display_task_log, view_task_result}; > use pbs_config::sync; > use pbs_tools::json::required_string_param; > @@ -667,6 +668,7 @@ async fn run() -> Result<(), Error> { > .init()?; > proxmox_backup::server::notifications::init()?; > proxmox_product_config::init(pbs_config::backup_user()?, pbs_config::priv_user()?); > + proxmox_acme_api::init(configdir!("/acme"), false)?; > > let cmd_def = CliCommandMap::new() > .insert("acl", acl_commands()) > diff --git a/src/bin/proxmox-backup-proxy.rs b/src/bin/proxmox-backup-proxy.rs > index 870208fe..eea44a7d 100644 > --- a/src/bin/proxmox-backup-proxy.rs > +++ b/src/bin/proxmox-backup-proxy.rs > @@ -188,6 +188,7 @@ async fn run() -> Result<(), Error> { > proxmox_backup::server::notifications::init()?; > metric_collection::init()?; > proxmox_product_config::init(pbs_config::backup_user()?, pbs_config::priv_user()?); > + proxmox_acme_api::init(configdir!("/acme"), false)?; > > let mut indexpath = PathBuf::from(pbs_buildcfg::JS_DIR); > indexpath.push("index.hbs"); > -- > 2.47.3 > > > > _______________________________________________ > pbs-devel mailing list > pbs-devel@lists.proxmox.com > https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel > > > _______________________________________________ pbs-devel mailing list pbs-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel