[pbs-devel] [PATCH proxmox 02/13] meta: add empty proxmox-http sub-crate

Fabian Grünbichler f.gruenbichler at proxmox.com
Fri May 14 15:44:38 CEST 2021


Signed-off-by: Fabian Grünbichler <f.gruenbichler at proxmox.com>
---
 Makefile                          |   2 +-
 Cargo.toml                        |   1 +
 proxmox-http/Cargo.toml           |  20 +++
 proxmox-http/debian/changelog     |   5 +
 proxmox-http/debian/control       | 230 ++++++++++++++++++++++++++++++
 proxmox-http/debian/copyright     |  16 +++
 proxmox-http/debian/debcargo.toml |   7 +
 proxmox-http/src/lib.rs           |   0
 8 files changed, 280 insertions(+), 1 deletion(-)
 create mode 100644 proxmox-http/Cargo.toml
 create mode 100644 proxmox-http/debian/changelog
 create mode 100644 proxmox-http/debian/control
 create mode 100644 proxmox-http/debian/copyright
 create mode 100644 proxmox-http/debian/debcargo.toml
 create mode 100644 proxmox-http/src/lib.rs

diff --git a/Makefile b/Makefile
index ebaf113..4f74539 100644
--- a/Makefile
+++ b/Makefile
@@ -1,6 +1,6 @@
 # Shortcut for common operations:
 
-CRATES=proxmox proxmox-api-macro proxmox-sortable-macro
+CRATES=proxmox proxmox-api-macro proxmox-http proxmox-sortable-macro
 
 # By default we just run checks:
 .PHONY: all
diff --git a/Cargo.toml b/Cargo.toml
index d6dc7b4..12e832d 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -2,6 +2,7 @@
 members = [
     "proxmox",
     "proxmox-api-macro",
+    "proxmox-http",
     "proxmox-sortable-macro",
 ]
 exclude = [
diff --git a/proxmox-http/Cargo.toml b/proxmox-http/Cargo.toml
new file mode 100644
index 0000000..9c2d3c5
--- /dev/null
+++ b/proxmox-http/Cargo.toml
@@ -0,0 +1,20 @@
+[package]
+name = "proxmox-http"
+edition = "2018"
+version = "0.1.0"
+authors = [
+    "Dietmar Maurer <dietmar at proxmox.com>",
+    "Wolfgang Bumiller <w.bumiller at proxmox.com>",
+]
+license = "AGPL-3"
+description = "Proxmox HTTP library"
+
+exclude = [ "debian" ]
+
+[dependencies]
+
+[features]
+default = []
+
+client = []
+websocket = []
diff --git a/proxmox-http/debian/changelog b/proxmox-http/debian/changelog
new file mode 100644
index 0000000..2ef333f
--- /dev/null
+++ b/proxmox-http/debian/changelog
@@ -0,0 +1,5 @@
+rust-proxmox-http (0.1.0-1) unstable; urgency=medium
+
+  * refactor code from proxmox-backup and proxmox into own HTTP crate
+
+ -- Proxmox Support Team <support at proxmox.com>  Tue, 11 May 2021 10:50:29 +0200
diff --git a/proxmox-http/debian/control b/proxmox-http/debian/control
new file mode 100644
index 0000000..f010d6e
--- /dev/null
+++ b/proxmox-http/debian/control
@@ -0,0 +1,230 @@
+Source: rust-proxmox-http
+Section: rust
+Priority: optional
+Build-Depends: debhelper (>= 11),
+ dh-cargo (>= 18),
+ cargo:native <!nocheck>,
+ rustc:native <!nocheck>,
+ libstd-rust-dev <!nocheck>,
+ librust-anyhow-1+default-dev <!nocheck>
+Maintainer: Proxmox Support Team <support at proxmox.com>
+Standards-Version: 4.4.1
+Vcs-Git: git://git.proxmox.com/git/proxmox.git
+Vcs-Browser: https://git.proxmox.com/?p=proxmox.git
+
+Package: librust-proxmox-http-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-anyhow-1+default-dev
+Suggests:
+ librust-proxmox-http+base64-dev (= ${binary:Version}),
+ librust-proxmox-http+client-dev (= ${binary:Version}),
+ librust-proxmox-http+futures-dev (= ${binary:Version}),
+ librust-proxmox-http+http-dev (= ${binary:Version}),
+ librust-proxmox-http+http-helpers-dev (= ${binary:Version}),
+ librust-proxmox-http+hyper-dev (= ${binary:Version}),
+ librust-proxmox-http+openssl-dev (= ${binary:Version}),
+ librust-proxmox-http+proxmox-dev (= ${binary:Version}),
+ librust-proxmox-http+tokio-dev (= ${binary:Version}),
+ librust-proxmox-http+tokio-openssl-dev (= ${binary:Version}),
+ librust-proxmox-http+websocket-dev (= ${binary:Version})
+Provides:
+ librust-proxmox-http+default-dev (= ${binary:Version}),
+ librust-proxmox-http-0-dev (= ${binary:Version}),
+ librust-proxmox-http-0+default-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+default-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+default-dev (= ${binary:Version})
+Description: Proxmox HTTP library - Rust source code
+ This package contains the source for the Rust proxmox-http crate, packaged by
+ debcargo for use with cargo and dh-cargo.
+
+Package: librust-proxmox-http+base64-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-proxmox-http-dev (= ${binary:Version}),
+ librust-base64-0.12+default-dev
+Provides:
+ librust-proxmox-http-0+base64-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+base64-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+base64-dev (= ${binary:Version})
+Description: Proxmox HTTP library - feature "base64"
+ This metapackage enables feature "base64" for the Rust proxmox-http crate, by
+ pulling in any additional dependencies needed by that feature.
+
+Package: librust-proxmox-http+client-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-proxmox-http-dev (= ${binary:Version}),
+ librust-proxmox-http+http-helpers-dev (= ${binary:Version}),
+ librust-futures-0.3+default-dev,
+ librust-openssl-0.10+default-dev
+Provides:
+ librust-proxmox-http-0+client-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+client-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+client-dev (= ${binary:Version})
+Description: Proxmox HTTP library - feature "client"
+ This metapackage enables feature "client" for the Rust proxmox-http crate, by
+ pulling in any additional dependencies needed by that feature.
+
+Package: librust-proxmox-http+futures-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-proxmox-http-dev (= ${binary:Version}),
+ librust-futures-0.3+default-dev
+Provides:
+ librust-proxmox-http-0+futures-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+futures-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+futures-dev (= ${binary:Version})
+Description: Proxmox HTTP library - feature "futures"
+ This metapackage enables feature "futures" for the Rust proxmox-http crate, by
+ pulling in any additional dependencies needed by that feature.
+
+Package: librust-proxmox-http+http-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-proxmox-http-dev (= ${binary:Version}),
+ librust-http-0.2+default-dev
+Provides:
+ librust-proxmox-http-0+http-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+http-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+http-dev (= ${binary:Version})
+Description: Proxmox HTTP library - feature "http"
+ This metapackage enables feature "http" for the Rust proxmox-http crate, by
+ pulling in any additional dependencies needed by that feature.
+
+Package: librust-proxmox-http+http-helpers-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-proxmox-http-dev (= ${binary:Version}),
+ librust-base64-0.12+default-dev,
+ librust-http-0.2+default-dev,
+ librust-hyper-0.14+default-dev,
+ librust-hyper-0.14+full-dev,
+ librust-proxmox-0.11-dev (>= 0.11.3-~~),
+ librust-tokio-1+io-util-dev,
+ librust-tokio-openssl-0.6+default-dev (>= 0.6.1-~~)
+Provides:
+ librust-proxmox-http+simple-client-dev (= ${binary:Version}),
+ librust-proxmox-http-0+http-helpers-dev (= ${binary:Version}),
+ librust-proxmox-http-0+simple-client-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+http-helpers-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+simple-client-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+http-helpers-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+simple-client-dev (= ${binary:Version})
+Description: Proxmox HTTP library - feature "http-helpers" and 1 more
+ This metapackage enables feature "http-helpers" for the Rust proxmox-http
+ crate, by pulling in any additional dependencies needed by that feature.
+ .
+ Additionally, this package also provides the "simple-client" feature.
+
+Package: librust-proxmox-http+hyper-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-proxmox-http-dev (= ${binary:Version}),
+ librust-hyper-0.14+default-dev,
+ librust-hyper-0.14+full-dev
+Provides:
+ librust-proxmox-http-0+hyper-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+hyper-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+hyper-dev (= ${binary:Version})
+Description: Proxmox HTTP library - feature "hyper"
+ This metapackage enables feature "hyper" for the Rust proxmox-http crate, by
+ pulling in any additional dependencies needed by that feature.
+
+Package: librust-proxmox-http+openssl-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-proxmox-http-dev (= ${binary:Version}),
+ librust-openssl-0.10+default-dev
+Provides:
+ librust-proxmox-http-0+openssl-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+openssl-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+openssl-dev (= ${binary:Version})
+Description: Proxmox HTTP library - feature "openssl"
+ This metapackage enables feature "openssl" for the Rust proxmox-http crate, by
+ pulling in any additional dependencies needed by that feature.
+
+Package: librust-proxmox-http+proxmox-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-proxmox-http-dev (= ${binary:Version}),
+ librust-proxmox-0.11-dev (>= 0.11.3-~~)
+Provides:
+ librust-proxmox-http-0+proxmox-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+proxmox-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+proxmox-dev (= ${binary:Version})
+Description: Proxmox HTTP library - feature "proxmox"
+ This metapackage enables feature "proxmox" for the Rust proxmox-http crate, by
+ pulling in any additional dependencies needed by that feature.
+
+Package: librust-proxmox-http+tokio-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-proxmox-http-dev (= ${binary:Version}),
+ librust-tokio-1+default-dev
+Provides:
+ librust-proxmox-http-0+tokio-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+tokio-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+tokio-dev (= ${binary:Version})
+Description: Proxmox HTTP library - feature "tokio"
+ This metapackage enables feature "tokio" for the Rust proxmox-http crate, by
+ pulling in any additional dependencies needed by that feature.
+
+Package: librust-proxmox-http+tokio-openssl-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-proxmox-http-dev (= ${binary:Version}),
+ librust-tokio-openssl-0.6+default-dev (>= 0.6.1-~~)
+Provides:
+ librust-proxmox-http-0+tokio-openssl-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+tokio-openssl-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+tokio-openssl-dev (= ${binary:Version})
+Description: Proxmox HTTP library - feature "tokio-openssl"
+ This metapackage enables feature "tokio-openssl" for the Rust proxmox-http
+ crate, by pulling in any additional dependencies needed by that feature.
+
+Package: librust-proxmox-http+websocket-dev
+Architecture: any
+Multi-Arch: same
+Depends:
+ ${misc:Depends},
+ librust-proxmox-http-dev (= ${binary:Version}),
+ librust-base64-0.12+default-dev,
+ librust-futures-0.3+default-dev,
+ librust-hyper-0.14+default-dev,
+ librust-hyper-0.14+full-dev,
+ librust-openssl-0.10+default-dev,
+ librust-proxmox-0.11+tokio-dev (>= 0.11.3-~~),
+ librust-tokio-1+io-util-dev,
+ librust-tokio-1+sync-dev
+Provides:
+ librust-proxmox-http-0+websocket-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1+websocket-dev (= ${binary:Version}),
+ librust-proxmox-http-0.1.0+websocket-dev (= ${binary:Version})
+Description: Proxmox HTTP library - feature "websocket"
+ This metapackage enables feature "websocket" for the Rust proxmox-http crate,
+ by pulling in any additional dependencies needed by that feature.
diff --git a/proxmox-http/debian/copyright b/proxmox-http/debian/copyright
new file mode 100644
index 0000000..2c91d38
--- /dev/null
+++ b/proxmox-http/debian/copyright
@@ -0,0 +1,16 @@
+Copyright (C) 2019,2020 Proxmox Server Solutions GmbH
+
+This software is written by Proxmox Server Solutions GmbH <support at proxmox.com>
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU Affero General Public License as published by
+the Free Software Foundation, either version 3 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU Affero General Public License for more details.
+
+You should have received a copy of the GNU Affero General Public License
+along with this program.  If not, see <http://www.gnu.org/licenses/>.
diff --git a/proxmox-http/debian/debcargo.toml b/proxmox-http/debian/debcargo.toml
new file mode 100644
index 0000000..b7864cd
--- /dev/null
+++ b/proxmox-http/debian/debcargo.toml
@@ -0,0 +1,7 @@
+overlay = "."
+crate_src_path = ".."
+maintainer = "Proxmox Support Team <support at proxmox.com>"
+
+[source]
+vcs_git = "git://git.proxmox.com/git/proxmox.git"
+vcs_browser = "https://git.proxmox.com/?p=proxmox.git"
diff --git a/proxmox-http/src/lib.rs b/proxmox-http/src/lib.rs
new file mode 100644
index 0000000..e69de29
-- 
2.20.1






More information about the pbs-devel mailing list