appmgr: ignore AlreadyExists error

This commit is contained in:
Aiden McClelland
2021-02-04 16:41:34 -07:00
committed by Aiden McClelland
parent 108213f920
commit c0e08df221

View File

@@ -23,7 +23,14 @@ impl VersionT for Version {
crate::tor::ETC_NGINX_SERVICES_CONF,
"/etc/nginx/sites-enabled/start9-services.conf",
)
.await?;
.await
.or_else(|e| {
if e.kind() == std::io::ErrorKind::AlreadyExists {
Ok(())
} else {
Err(e)
}
})?;
let svc_exit = std::process::Command::new("service")
.args(&["nginx", "reload"])
.status()?;