feat: mirror can set to none, set to rust when confit is none
This commit is contained in:
@@ -9,6 +9,15 @@ pub struct DockerBuildConfig {
|
||||
pub mirror: Option<String>,
|
||||
}
|
||||
|
||||
pub fn load_docker_build_config_or_default() -> DockerBuildConfig {
|
||||
load_docker_build_config().unwrap_or_else(|| {
|
||||
DockerBuildConfig {
|
||||
image: Some("rust".into()),
|
||||
mirror: None,
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
pub fn load_docker_build_config() -> Option<DockerBuildConfig> {
|
||||
let config = find_docker_build_config_file()?;
|
||||
success!("Find config file: {:?}", config);
|
||||
|
||||
Reference in New Issue
Block a user