runtime: default working directories to data dir
This commit is contained in:
parent
fa233ba025
commit
d216b10100
|
|
@ -123,10 +123,16 @@ fn working_directory_runtime_root(config: &ProcessConfig) -> PathBuf {
|
||||||
_ => config
|
_ => config
|
||||||
.worker_runtime_base_dir
|
.worker_runtime_base_dir
|
||||||
.clone()
|
.clone()
|
||||||
.unwrap_or_else(|| env::temp_dir().join("yoi-worker-runtime")),
|
.unwrap_or_else(default_working_directory_runtime_root),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fn default_working_directory_runtime_root() -> PathBuf {
|
||||||
|
manifest::paths::data_dir()
|
||||||
|
.map(|data_dir| data_dir.join("worker-runtime"))
|
||||||
|
.unwrap_or_else(|| env::temp_dir().join("yoi-worker-runtime"))
|
||||||
|
}
|
||||||
|
|
||||||
fn runtime_options_from_http(config: &RuntimeHttpServerConfig) -> RuntimeOptions {
|
fn runtime_options_from_http(config: &RuntimeHttpServerConfig) -> RuntimeOptions {
|
||||||
RuntimeOptions {
|
RuntimeOptions {
|
||||||
runtime_id: config.runtime_id.clone(),
|
runtime_id: config.runtime_id.clone(),
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user