|
|
@@ -12,6 +12,7 @@ use crate::{
|
|
|
ssh::{run_ssh, run_ssh_follow, run_ssh_with_retry},
|
|
|
};
|
|
|
|
|
|
+#[allow(clippy::too_many_arguments)]
|
|
|
pub async fn serve(
|
|
|
config: &Config,
|
|
|
recipe_name: &str,
|
|
|
@@ -19,6 +20,7 @@ pub async fn serve(
|
|
|
node_name: Option<&str>,
|
|
|
keep: bool,
|
|
|
skip_before_serve: bool,
|
|
|
+ follow: bool,
|
|
|
dry_run: bool,
|
|
|
) -> Result<()> {
|
|
|
let recipe = load_recipe(recipe_name).await?;
|
|
|
@@ -91,9 +93,9 @@ pub async fn serve(
|
|
|
dry_run,
|
|
|
)
|
|
|
.await?;
|
|
|
- if !dry_run {
|
|
|
+ if !dry_run && follow {
|
|
|
info!("{}", fluent_i18n::t!("container-log-header"));
|
|
|
- show_logs(config, &cluster, recipe_name, false, dry_run).await?;
|
|
|
+ show_logs(config, &cluster, recipe_name, true, dry_run).await?;
|
|
|
}
|
|
|
Ok(())
|
|
|
}
|