From: Hannes Duerr <h.duerr@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH proxmox-perl-rs] pve-rs: remove PVE::RS::APT:Repositories module
Date: Thu, 15 May 2025 10:31:48 +0200 [thread overview]
Message-ID: <20250515083148.11897-1-h.duerr@proxmox.com> (raw)
We can remove the PVE::RS::APT::Repositories module because we needed
its functionality in Proxmox VE and other products, so we moved it to
Proxmox::RS::APT::Repositories some time ago. We now only use the new
module in our code.
When users update to Proxmox VE 9, we can be sure that there is no
package using PVE::RS::APT::Repositories, so we can safely remove the
code.
Signed-off-by: Hannes Duerr <h.duerr@proxmox.com>
---
This patch should only be applied with Proxmox VE version 9
pve-rs/Makefile | 1 -
pve-rs/src/apt/mod.rs | 1 -
pve-rs/src/apt/repositories.rs | 42 ----------------------------------
pve-rs/src/lib.rs | 1 -
4 files changed, 45 deletions(-)
delete mode 100644 pve-rs/src/apt/mod.rs
delete mode 100644 pve-rs/src/apt/repositories.rs
diff --git a/pve-rs/Makefile b/pve-rs/Makefile
index ae7f2e2..9ca6e64 100644
--- a/pve-rs/Makefile
+++ b/pve-rs/Makefile
@@ -27,7 +27,6 @@ PERLMOD_GENPACKAGE := /usr/lib/perlmod/genpackage.pl \
--include-file=Fixup.pm
PERLMOD_PACKAGES := \
- PVE::RS::APT::Repositories \
PVE::RS::Firewall::SDN \
PVE::RS::OpenId \
PVE::RS::ResourceScheduling::Static \
diff --git a/pve-rs/src/apt/mod.rs b/pve-rs/src/apt/mod.rs
deleted file mode 100644
index 574c1a7..0000000
--- a/pve-rs/src/apt/mod.rs
+++ /dev/null
@@ -1 +0,0 @@
-mod repositories;
diff --git a/pve-rs/src/apt/repositories.rs b/pve-rs/src/apt/repositories.rs
deleted file mode 100644
index 7fbf97c..0000000
--- a/pve-rs/src/apt/repositories.rs
+++ /dev/null
@@ -1,42 +0,0 @@
-#[perlmod::package(name = "PVE::RS::APT::Repositories", lib = "pve_rs")]
-mod export {
- use anyhow::Error;
-
- use proxmox_apt_api_types::{
- APTChangeRepositoryOptions, APTRepositoriesResult, APTRepositoryHandle,
- };
- use proxmox_config_digest::ConfigDigest;
-
- use crate::common::apt::repositories::export as common;
-
- /// Get information about configured and standard repositories.
- #[export]
- pub fn repositories() -> Result<APTRepositoriesResult, Error> {
- proxmox_apt::list_repositories("pve")
- }
-
- /// Add the repository identified by the `handle`.
- /// If the repository is already configured, it will be set to enabled.
- ///
- /// The `digest` parameter asserts that the configuration has not been modified.
- #[export]
- pub fn add_repository(
- handle: APTRepositoryHandle,
- digest: Option<ConfigDigest>,
- ) -> Result<(), Error> {
- common::add_repository(handle, "pve", digest)
- }
-
- /// Change the properties of the specified repository.
- ///
- /// The `digest` parameter asserts that the configuration has not been modified.
- #[export]
- pub fn change_repository(
- path: &str,
- index: usize,
- options: APTChangeRepositoryOptions,
- digest: Option<ConfigDigest>,
- ) -> Result<(), Error> {
- common::change_repository(path, index, options, digest)
- }
-}
diff --git a/pve-rs/src/lib.rs b/pve-rs/src/lib.rs
index 3de37d1..755db12 100644
--- a/pve-rs/src/lib.rs
+++ b/pve-rs/src/lib.rs
@@ -11,7 +11,6 @@ use proxmox_notify::{Config, Notification, Severity};
#[path = "../common/src/mod.rs"]
pub mod common;
-pub mod apt;
pub mod firewall;
pub mod openid;
pub mod resource_scheduling;
--
2.39.5
_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
next reply other threads:[~2025-05-15 8:31 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-15 8:31 Hannes Duerr [this message]
2025-05-16 12:57 ` [pve-devel] applied: " Wolfgang Bumiller
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=20250515083148.11897-1-h.duerr@proxmox.com \
--to=h.duerr@proxmox.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