[pve-devel] [PATCH installer v4 10/12] fix #5536: auto-installer: answer: add `posthook` section
Christoph Heiss
c.heiss at proxmox.com
Mon Nov 11 14:15:06 CET 2024
Signed-off-by: Christoph Heiss <c.heiss at proxmox.com>
---
Changes v3 -> v4:
* no changes
Changes v2 -> v3:
* no changes
Changes v1 -> v2:
* no changes
proxmox-auto-installer/src/answer.rs | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/proxmox-auto-installer/src/answer.rs b/proxmox-auto-installer/src/answer.rs
index 8a4f9ef..c23f1f3 100644
--- a/proxmox-auto-installer/src/answer.rs
+++ b/proxmox-auto-installer/src/answer.rs
@@ -20,6 +20,8 @@ pub struct Answer {
pub network: Network,
#[serde(rename = "disk-setup")]
pub disks: Disks,
+ #[serde(default)]
+ pub posthook: Option<PostNotificationHookInfo>,
}
impl Answer {
@@ -51,6 +53,15 @@ pub struct Global {
pub root_ssh_keys: Vec<String>,
}
+#[derive(Clone, Deserialize, Debug)]
+#[serde(deny_unknown_fields)]
+pub struct PostNotificationHookInfo {
+ /// URL to send a POST request to
+ pub url: String,
+ /// SHA256 cert fingerprint if certificate pinning should be used.
+ pub cert_fingerprint: Option<String>,
+}
+
#[derive(Clone, Deserialize, Debug, Default, PartialEq)]
#[serde(deny_unknown_fields)]
enum NetworkConfigMode {
--
2.47.0
More information about the pve-devel
mailing list