Catching a docker rm problem
This commit is contained in:
@@ -178,7 +178,9 @@ pub async fn handle_project_rebuild(
|
|||||||
if let Err(e) = docker_stop(&container_name).await {
|
if let Err(e) = docker_stop(&container_name).await {
|
||||||
crate::slog!("[project-rebuild] stop '{container_name}': {e} (may already be stopped)");
|
crate::slog!("[project-rebuild] stop '{container_name}': {e} (may already be stopped)");
|
||||||
}
|
}
|
||||||
if let Err(e) = docker_rm(&container_name).await {
|
if let Err(e) = docker_rm(&container_name).await
|
||||||
|
&& !e.contains("No such container")
|
||||||
|
{
|
||||||
return format!(
|
return format!(
|
||||||
"Rebuild failed at **container remove** step.\n\
|
"Rebuild failed at **container remove** step.\n\
|
||||||
Error: {e}\n\n\
|
Error: {e}\n\n\
|
||||||
|
|||||||
Reference in New Issue
Block a user