Skip to content

Commit

Permalink
Fix rebase of --inherit-network
Browse files Browse the repository at this point in the history
  • Loading branch information
alexcrichton committed Sep 9, 2023
1 parent f5c1bb9 commit fed118c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions crates/cli-flags/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,9 @@ wasmtime_option_group! {
/// available is dependent on the backends implemented in the
/// `wasmtime_wasi_nn` crate.
pub nn_graph: Vec<WasiNnGraph>,
/// Flag for WASI preview2 to inherit the host's network within the
/// guest so it has full access to all addresses/ports/etc.
pub inherit_network: Option<bool>,

}

Expand Down
2 changes: 1 addition & 1 deletion src/commands/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -943,7 +943,7 @@ impl RunCommand {
);
}

if self.inherit_network {
if self.common.wasi.inherit_network == Some(true) {
builder.inherit_network(ambient_authority());
}

Expand Down

0 comments on commit fed118c

Please sign in to comment.