}
enum Release {
+ Bookworm,
Bullseye,
Buster,
}
impl Display for Release {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match self {
+ Release::Bookworm => write!(f, "bookworm"),
Release::Bullseye => write!(f, "bullseye"),
Release::Buster => write!(f, "buster"),
}
skip_sections,
};
let url = match (release, variant) {
+ (Release::Bookworm, DebianVariant::Main) => "http://deb.debian.org/debian bookworm",
+ (Release::Bookworm, DebianVariant::Security) => {
+ "http://deb.debian.org/debian-security bookworm-security"
+ }
+ (Release::Bookworm, DebianVariant::Updates) => {
+ "http://deb.debian.org/debian bookworm-updates"
+ }
+ (Release::Bookworm, DebianVariant::Backports) => {
+ "http://deb.debian.org/debian bookworm-backports"
+ }
+ (Release::Bookworm, DebianVariant::Debug) => {
+ "http://deb.debian.org/debian-debug bookworm-debug"
+ }
(Release::Bullseye, DebianVariant::Main) => "http://deb.debian.org/debian bullseye",
(Release::Bullseye, DebianVariant::Security) => {
"http://deb.debian.org/debian-security bullseye-security"
let url = format!("{url} {components}");
let key = match (release, variant) {
+ (Release::Bookworm, DebianVariant::Security) => {
+ "/usr/share/keyrings/debian-archive-bookworm-security-automatic.gpg"
+ }
+ (Release::Bookworm, DebianVariant::Updates) |
+ (Release::Bookworm, DebianVariant::Backports) => {
+ "/usr/share/keyrings/debian-archive-bookworm-automatic.gpg"
+ }
+ (Release::Bookworm, _) => "/usr/share/keyrings/debian-archive-bookworm-stable.gpg",
(Release::Bullseye, DebianVariant::Security) => {
"/usr/share/keyrings/debian-archive-bullseye-security-automatic.gpg"
}
];
let dist = read_selection_from_tty("Select distro to mirror", distros, None)?;
- let releases = &[(Release::Bullseye, "Bullseye"), (Release::Buster, "Buster")];
+ let releases = &[
+ (Release::Bookworm, "Bookworm"),
+ (Release::Bullseye, "Bullseye"),
+ (Release::Buster, "Buster"),
+ ];
let release = read_selection_from_tty("Select release", releases, Some(0))?;
let mut add_debian_repo = false;
}
let releases = match release {
+ &Release::Bookworm => vec![(CephRelease::Quincy, "Quincy (17.x)")],
Release::Bullseye => {
vec![
(CephRelease::Octopus, "Octopus (15.x)"),
read_string_from_tty("Enter repository components", Some("main test"))?;
let key = match release {
+ Release::Bookworm => "/etc/apt/trusted.gpg.d/proxmox-release-bookworm.gpg",
Release::Bullseye => "/etc/apt/trusted.gpg.d/proxmox-release-bullseye.gpg",
Release::Buster => "/etc/apt/trusted.gpg.d/proxmox-release-buster.gpg",
};
// TODO enterprise query for key!
let url = match (release, variant) {
+ (Release::Bookworm, ProxmoxVariant::Enterprise) => format!("https://enterprise.proxmox.com/debian/{product} bookworm {product}-enterprise"),
+ (Release::Bookworm, ProxmoxVariant::NoSubscription) => format!("http://download.proxmox.com/debian/{product} bookworm {product}-no-subscription"),
+ (Release::Bookworm, ProxmoxVariant::Test) => format!("http://download.proxmox.com/debian/{product} bookworm {product}test"),
(Release::Bullseye, ProxmoxVariant::Enterprise) => format!("https://enterprise.proxmox.com/debian/{product} bullseye {product}-enterprise"),
(Release::Bullseye, ProxmoxVariant::NoSubscription) => format!("http://download.proxmox.com/debian/{product} bullseye {product}-no-subscription"),
(Release::Bullseye, ProxmoxVariant::Test) => format!("http://download.proxmox.com/debian/{product} bullseye {product}test"),
};
let key = match release {
+ Release::Bookworm => "/etc/apt/trusted.gpg.d/proxmox-release-bookworm.gpg",
Release::Bullseye => "/etc/apt/trusted.gpg.d/proxmox-release-bullseye.gpg",
Release::Buster => "/etc/apt/trusted.gpg.d/proxmox-release-buster.gpg",
};