bump proxmox crate to 0.1.7
The -sys, -tools and -api crate have now been merged into the proxmx crate directly. Only macro crates are separate (but still reexported by the proxmox crate in their designated locations). When we need to depend on "parts" of the crate later on we'll just have to use features. The reason is mostly that these modules had inter-dependencies which really make them not independent enough to be their own crates. Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
@ -2,10 +2,10 @@ use failure::*;
|
||||
|
||||
use serde_json::{json, Value};
|
||||
|
||||
use proxmox::sortable;
|
||||
use proxmox::api::{http_err, list_subdirs_api_method};
|
||||
use proxmox::api::router::{Router, SubdirMap};
|
||||
use proxmox::api::api;
|
||||
use proxmox::api::router::{Router, SubdirMap};
|
||||
use proxmox::sortable;
|
||||
use proxmox::{http_err, list_subdirs_api_method};
|
||||
|
||||
use crate::tools;
|
||||
use crate::tools::ticket::*;
|
||||
|
@ -1,5 +1,5 @@
|
||||
use proxmox::api::router::{Router, SubdirMap};
|
||||
use proxmox::api::list_subdirs_api_method;
|
||||
use proxmox::list_subdirs_api_method;
|
||||
|
||||
pub mod datastore;
|
||||
|
||||
|
@ -7,14 +7,13 @@ use hyper::http::request::Parts;
|
||||
use hyper::{header, Body, Response, StatusCode};
|
||||
use serde_json::{json, Value};
|
||||
|
||||
use proxmox::{sortable, identity};
|
||||
use proxmox::api::api;
|
||||
use proxmox::api::{http_err, list_subdirs_api_method};
|
||||
use proxmox::api::{ApiResponseFuture, ApiHandler, ApiMethod, Router, RpcEnvironment, RpcEnvironmentType};
|
||||
use proxmox::api::router::SubdirMap;
|
||||
use proxmox::api::schema::*;
|
||||
use proxmox::tools::try_block;
|
||||
use proxmox::tools::fs::{file_get_contents, replace_file, CreateOptions};
|
||||
use proxmox::try_block;
|
||||
use proxmox::{http_err, identity, list_subdirs_api_method, sortable};
|
||||
|
||||
use crate::api2::types::*;
|
||||
use crate::backup::*;
|
||||
|
@ -5,8 +5,7 @@ use hyper::http::request::Parts;
|
||||
use hyper::{Body, Response, StatusCode};
|
||||
use serde_json::{json, Value};
|
||||
|
||||
use proxmox::{sortable, identity};
|
||||
use proxmox::api::list_subdirs_api_method;
|
||||
use proxmox::{sortable, identity, list_subdirs_api_method};
|
||||
use proxmox::api::{ApiResponseFuture, ApiHandler, ApiMethod, Router, RpcEnvironment};
|
||||
use proxmox::api::router::SubdirMap;
|
||||
use proxmox::api::schema::*;
|
||||
|
@ -58,7 +58,7 @@ impl Future for UploadChunk {
|
||||
break format_err!("uploaded chunk has unexpected size.");
|
||||
}
|
||||
|
||||
let (is_duplicate, compressed_size) = match proxmox::tools::try_block! {
|
||||
let (is_duplicate, compressed_size) = match proxmox::try_block! {
|
||||
let mut chunk = DataBlob::from_raw(raw_data)?;
|
||||
|
||||
chunk.verify_unencrypted(this.size as usize, &this.digest)?;
|
||||
|
@ -1,5 +1,5 @@
|
||||
use proxmox::api::router::{Router, SubdirMap};
|
||||
use proxmox::api::list_subdirs_api_method;
|
||||
use proxmox::list_subdirs_api_method;
|
||||
|
||||
pub mod datastore;
|
||||
pub mod remote;
|
||||
|
@ -1,5 +1,5 @@
|
||||
use proxmox::api::router::{Router, SubdirMap};
|
||||
use proxmox::api::list_subdirs_api_method;
|
||||
use proxmox::list_subdirs_api_method;
|
||||
|
||||
mod tasks;
|
||||
mod time;
|
||||
|
@ -10,7 +10,7 @@ use proxmox::{sortable, identity};
|
||||
use proxmox::api::{ApiHandler, ApiMethod, Router, RpcEnvironment};
|
||||
use proxmox::api::schema::*;
|
||||
use proxmox::tools::fs::{file_get_contents, replace_file, CreateOptions};
|
||||
use proxmox::tools::*; // required to use IPRE!() macro ???
|
||||
use proxmox::{IPRE, IPV4RE, IPV6RE, IPV4OCTET, IPV6H16, IPV6LS32};
|
||||
|
||||
use crate::api2::types::*;
|
||||
|
||||
|
@ -3,8 +3,7 @@ use std::process::{Command, Stdio};
|
||||
use failure::*;
|
||||
use serde_json::{json, Value};
|
||||
|
||||
use proxmox::{sortable, identity};
|
||||
use proxmox::api::list_subdirs_api_method;
|
||||
use proxmox::{sortable, identity, list_subdirs_api_method};
|
||||
use proxmox::api::{ApiHandler, ApiMethod, Router, RpcEnvironment};
|
||||
use proxmox::api::router::SubdirMap;
|
||||
use proxmox::api::schema::*;
|
||||
|
@ -4,7 +4,7 @@ use serde_json::{json, Value};
|
||||
use proxmox::sys::linux::procfs;
|
||||
|
||||
use proxmox::api::{api, ApiMethod, Router, RpcEnvironment, SubdirMap};
|
||||
use proxmox::api::list_subdirs_api_method;
|
||||
use proxmox::list_subdirs_api_method;
|
||||
|
||||
use crate::api2::types::*;
|
||||
|
||||
|
@ -4,11 +4,10 @@ use std::io::{BufRead, BufReader};
|
||||
use failure::*;
|
||||
use serde_json::{json, Value};
|
||||
|
||||
use proxmox::{sortable, identity};
|
||||
use proxmox::api::list_subdirs_api_method;
|
||||
use proxmox::api::{ApiHandler, ApiMethod, Router, RpcEnvironment};
|
||||
use proxmox::api::router::SubdirMap;
|
||||
use proxmox::api::schema::*;
|
||||
use proxmox::{identity, list_subdirs_api_method, sortable};
|
||||
|
||||
use crate::tools;
|
||||
use crate::api2::types::*;
|
||||
|
@ -128,7 +128,7 @@ async fn pull_snapshot(
|
||||
tmp_manifest_blob.verify_crc()?;
|
||||
|
||||
if manifest_name.exists() {
|
||||
let manifest_blob = proxmox::tools::try_block!({
|
||||
let manifest_blob = proxmox::try_block!({
|
||||
let mut manifest_file = std::fs::File::open(&manifest_name)
|
||||
.map_err(|err| format_err!("unable to open local manifest {:?} - {}", manifest_name, err))?;
|
||||
|
||||
@ -331,7 +331,7 @@ pub async fn pull_store(
|
||||
}
|
||||
|
||||
if delete {
|
||||
let result: Result<(), Error> = proxmox::tools::try_block!({
|
||||
let result: Result<(), Error> = proxmox::try_block!({
|
||||
let local_groups = BackupGroup::list_groups(&tgt_store.base_path())?;
|
||||
for local_group in local_groups {
|
||||
if new_groups.contains(&local_group) { continue; }
|
||||
|
@ -7,9 +7,9 @@ use hyper::{Body, Response, StatusCode};
|
||||
use serde_json::Value;
|
||||
|
||||
use proxmox::{sortable, identity};
|
||||
use proxmox::api::http_err;
|
||||
use proxmox::api::{ApiResponseFuture, ApiHandler, ApiMethod, Router, RpcEnvironment};
|
||||
use proxmox::api::schema::*;
|
||||
use proxmox::http_err;
|
||||
|
||||
use crate::api2::types::*;
|
||||
use crate::backup::*;
|
||||
|
@ -1,8 +1,9 @@
|
||||
use failure::*;
|
||||
use ::serde::{Deserialize, Serialize};
|
||||
|
||||
use proxmox::api::{api, const_regex, schema::*};
|
||||
use proxmox::tools::*; // required to use IPRE!() macro ???
|
||||
use proxmox::api::{api, schema::*};
|
||||
use proxmox::const_regex;
|
||||
use proxmox::{IPRE, IPV4RE, IPV6RE, IPV4OCTET, IPV6H16, IPV6LS32};
|
||||
|
||||
// File names: may not contain slashes, may not start with "."
|
||||
pub const FILENAME_FORMAT: ApiStringFormat = ApiStringFormat::VerifyFn(|name| {
|
||||
|
Reference in New Issue
Block a user