Skip to content

Commit

Permalink
Merge pull request #108 from containers/compose-network
Browse files Browse the repository at this point in the history
fix(compose): append `.network` to container network name
  • Loading branch information
k9withabone authored Sep 27, 2024
2 parents 5356c2f + 2bcd094 commit 000daa3
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/cli/container/quadlet.rs
Original file line number Diff line number Diff line change
Expand Up @@ -910,11 +910,12 @@ fn network_config_try_into_network_options(
NetworkConfig::Networks(networks) => networks
.into_long()
.into_iter()
.map(|(network, options)| {
let mut network = String::from(network);
.map(|(identifier, options)| {
let mut network = String::from(identifier.clone());
network.push_str(".network");
if let Some(options) = options {
let options = network_options(options).wrap_err_with(|| {
format!("error converting `{network}` network options")
format!("error converting `{identifier}` network options")
})?;
network.push(':');
network.push_str(&options);
Expand Down

0 comments on commit 000daa3

Please sign in to comment.