mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-26 18:31:52 +00:00
fix locker issues
This commit is contained in:
@@ -13,7 +13,9 @@ use crate::config::{Config, ConfigSpec};
|
||||
use crate::context::RpcContext;
|
||||
use crate::id::{Id, InvalidId};
|
||||
use crate::s9pk::manifest::PackageId;
|
||||
use crate::util::{IoFormat, ValuePrimative, Version, display_serializable, parse_stdin_deserializable};
|
||||
use crate::util::{
|
||||
display_serializable, parse_stdin_deserializable, IoFormat, ValuePrimative, Version,
|
||||
};
|
||||
use crate::volume::Volumes;
|
||||
use crate::{Error, ResultExt};
|
||||
|
||||
@@ -80,7 +82,7 @@ pub enum ActionResult {
|
||||
#[derive(Debug, Serialize, Deserialize)]
|
||||
pub struct ActionResultV0 {
|
||||
pub message: String,
|
||||
pub value: ValuePrimative,
|
||||
pub value: Option<String>,
|
||||
pub copyable: bool,
|
||||
pub qr: bool,
|
||||
}
|
||||
@@ -183,8 +185,12 @@ fn display_action_result(action_result: ActionResult, matches: &ArgMatches<'_>)
|
||||
}
|
||||
match action_result {
|
||||
ActionResult::V0(ar) => {
|
||||
println!("{}: {}", ar.message, serde_json::to_string(&ar.value).unwrap());
|
||||
},
|
||||
println!(
|
||||
"{}: {}",
|
||||
ar.message,
|
||||
serde_json::to_string(&ar.value).unwrap()
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -351,7 +351,8 @@ impl Manager {
|
||||
.await
|
||||
{
|
||||
Err(bollard::errors::Error::DockerResponseNotFoundError { .. })
|
||||
| Err(bollard::errors::Error::DockerResponseConflictError { .. }) => (), // Already stopped
|
||||
| Err(bollard::errors::Error::DockerResponseConflictError { .. })
|
||||
| Err(bollard::errors::Error::DockerResponseNotModifiedError { .. }) => (), // Already stopped
|
||||
a => a?,
|
||||
};
|
||||
self.shared.status.store(
|
||||
@@ -413,7 +414,8 @@ impl Manager {
|
||||
.await
|
||||
{
|
||||
Err(bollard::errors::Error::DockerResponseNotFoundError { .. })
|
||||
| Err(bollard::errors::Error::DockerResponseConflictError { .. }) => (),
|
||||
| Err(bollard::errors::Error::DockerResponseConflictError { .. })
|
||||
| Err(bollard::errors::Error::DockerResponseNotModifiedError { .. }) => (), // Already stopped
|
||||
a => a?,
|
||||
};
|
||||
self.shared.status.store(
|
||||
|
||||
@@ -301,7 +301,9 @@ impl MainStatus {
|
||||
},
|
||||
ManagerStatus::Running => match self {
|
||||
MainStatus::Stopped | MainStatus::Stopping | MainStatus::Restoring { .. } => {
|
||||
dbg!("stopping");
|
||||
manager.stop().await?;
|
||||
dbg!("stopped");
|
||||
}
|
||||
MainStatus::Running { .. } => (),
|
||||
MainStatus::BackingUp { .. } => {
|
||||
|
||||
2
patch-db
2
patch-db
Submodule patch-db updated: 96ab78f8b0...d26e1563e8
Reference in New Issue
Block a user