rename data_store to datastore

This commit is contained in:
Dietmar Maurer 2018-12-08 14:51:08 +01:00
parent 6ce50400c5
commit 567713b4c3
3 changed files with 8 additions and 2 deletions

View File

@ -5,8 +5,14 @@ use crate::api::schema::*;
use crate::api::router::*; use crate::api::router::*;
use serde_json::{json, Value}; use serde_json::{json, Value};
use crate::config::datastore;
fn datastore_list(param: Value, _info: &ApiMethod) -> Result<Value, Error> { fn datastore_list(param: Value, _info: &ApiMethod) -> Result<Value, Error> {
println!("This is a test {}", param); println!("This is a test {}", param);
let config = datastore::config().unwrap();
Ok(json!({})) Ok(json!({}))
} }

View File

@ -34,7 +34,7 @@ fn init() -> SectionConfig {
const DATASTORE_CFG_FILENAME: &str = "/etc/proxmox-backup/datastore.cfg"; const DATASTORE_CFG_FILENAME: &str = "/etc/proxmox-backup/datastore.cfg";
fn config() -> Result<SectionConfigData, Error> { pub fn config() -> Result<SectionConfigData, Error> {
let mut file = match OpenOptions::new() let mut file = match OpenOptions::new()
.create(true) .create(true)

View File

@ -37,7 +37,7 @@ pub mod backup {
pub mod config { pub mod config {
pub mod data_store; pub mod datastore;
} }
pub mod storage { pub mod storage {