Skip to content

Commit

Permalink
Merge pull request #123 from containers/podman-v5.2.0
Browse files Browse the repository at this point in the history
Podman v5.2.0
  • Loading branch information
k9withabone authored Oct 20, 2024
2 parents f93a4db + f3a88d9 commit 8ef9420
Show file tree
Hide file tree
Showing 13 changed files with 1,341 additions and 90 deletions.
19 changes: 16 additions & 3 deletions src/cli.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
mod build;
mod compose;
mod container;
mod generate;
Expand Down Expand Up @@ -36,9 +37,9 @@ use path_clean::PathClean;
use crate::quadlet::{self, Downgrade, DowngradeError, Globals, HostPaths, PodmanVersion};

use self::{
compose::Compose, container::Container, generate::Generate, global_args::GlobalArgs,
image::Image, install::Install, kube::Kube, network::Network, pod::Pod, service::Service,
unit::Unit, volume::Volume,
build::Build, compose::Compose, container::Container, generate::Generate,
global_args::GlobalArgs, image::Image, install::Install, kube::Kube, network::Network,
pod::Pod, service::Service, unit::Unit, volume::Volume,
};

#[allow(clippy::option_option)]
Expand Down Expand Up @@ -448,6 +449,16 @@ enum PodmanCommands {
volume: Volume,
},

/// Generate a Podman Quadlet `.build` file
///
/// For details on options see:
/// https://docs.podman.io/en/stable/markdown/podman-build.1.html
Build {
/// The \[Build\] section
#[command(flatten)]
build: Box<Build>,
},

/// Generate a Podman Quadlet `.image` file
///
/// For details on options see:
Expand All @@ -467,6 +478,7 @@ impl From<PodmanCommands> for quadlet::Resource {
PodmanCommands::Kube { kube } => (*kube).into(),
PodmanCommands::Network { network } => (*network).into(),
PodmanCommands::Volume { volume } => volume.into(),
PodmanCommands::Build { build } => (*build).into(),
PodmanCommands::Image { image } => (*image).into(),
}
}
Expand Down Expand Up @@ -507,6 +519,7 @@ impl PodmanCommands {
Self::Kube { kube } => kube.name(),
Self::Network { network } => network.name(),
Self::Volume { volume } => volume.name(),
Self::Build { build } => build.name(),
Self::Image { image } => image.name(),
}
}
Expand Down
Loading

0 comments on commit 8ef9420

Please sign in to comment.