[pdm-devel] [PATCH datacenter-manager 02/13] pbs-client: add bindings for /nodes/localhost/apt/versions
Lukas Wagner
l.wagner at proxmox.com
Thu Nov 27 11:44:36 CET 2025
This allows us to get the most important package versions of a PBS
remote.
Signed-off-by: Lukas Wagner <l.wagner at proxmox.com>
---
server/src/pbs_client.rs | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/server/src/pbs_client.rs b/server/src/pbs_client.rs
index 00f6030c..3a899084 100644
--- a/server/src/pbs_client.rs
+++ b/server/src/pbs_client.rs
@@ -353,6 +353,16 @@ impl PbsClient {
Ok(self.0.get(&path).await?.expect_json()?.data)
}
+ /// Return a list of the most important package versions.
+ pub async fn get_package_versions(&self) -> Result<Vec<pbs_api_types::APTUpdateInfo>, Error> {
+ Ok(self
+ .0
+ .get("/api2/extjs/nodes/localhost/apt/versions")
+ .await?
+ .expect_json()?
+ .data)
+ }
+
/// Get list of tasks.
///
/// `params`: Filters specifying which tasks to get.
--
2.47.3
More information about the pdm-devel
mailing list