nixfleet_proto/
evidence_signing.rs1use chrono::{DateTime, Utc};
5use serde::Serialize;
6
7#[derive(Debug, Clone, Serialize)]
8#[serde(rename_all = "camelCase")]
9pub struct ActivationFailedSignedPayload<'a> {
10 pub hostname: &'a str,
11 pub rollout: Option<&'a str>,
12 pub phase: &'a str,
13 pub exit_code: Option<i32>,
14 pub stderr_tail_sha256: String,
16}
17
18#[derive(Debug, Clone, Serialize)]
19#[serde(rename_all = "camelCase")]
20pub struct RollbackTriggeredSignedPayload<'a> {
21 pub hostname: &'a str,
22 pub rollout: Option<&'a str>,
23 pub reason: &'a str,
24}
25
26#[derive(Debug, Clone, Serialize)]
31#[serde(rename_all = "camelCase")]
32pub struct LastConfirmedAtSignedPayload<'a> {
33 pub hostname: &'a str,
34 pub rollout_id: &'a str,
35 pub last_confirmed_at: DateTime<Utc>,
36}
37
38#[derive(Debug, Clone, Serialize)]
39#[serde(rename_all = "camelCase")]
40pub struct RealiseFailedSignedPayload<'a> {
41 pub hostname: &'a str,
42 pub rollout: Option<&'a str>,
43 pub closure_hash: &'a str,
44 pub reason: &'a str,
45}
46
47#[derive(Debug, Clone, Serialize)]
48#[serde(rename_all = "camelCase")]
49pub struct VerifyMismatchSignedPayload<'a> {
50 pub hostname: &'a str,
51 pub rollout: Option<&'a str>,
52 pub expected: &'a str,
53 pub actual: &'a str,
54}
55
56#[derive(Debug, Clone, Serialize)]
57#[serde(rename_all = "camelCase")]
58pub struct ClosureSignatureMismatchSignedPayload<'a> {
59 pub hostname: &'a str,
60 pub rollout: Option<&'a str>,
61 pub closure_hash: &'a str,
62 pub stderr_tail_sha256: String,
64}
65
66#[derive(Debug, Clone, Serialize)]
67#[serde(rename_all = "camelCase")]
68pub struct StaleTargetSignedPayload<'a> {
69 pub hostname: &'a str,
70 pub rollout: Option<&'a str>,
71 pub closure_hash: &'a str,
72 pub channel_ref: &'a str,
73 pub signed_at: DateTime<Utc>,
74 pub freshness_window_secs: u32,
75 pub age_secs: i64,
76}
77
78#[derive(Debug, Clone, Serialize)]
80#[serde(rename_all = "camelCase")]
81pub struct ManifestMissingSignedPayload<'a> {
82 pub hostname: &'a str,
83 pub rollout: Option<&'a str>,
84 pub rollout_id: &'a str,
85 pub reason: &'a str,
86}
87
88#[derive(Debug, Clone, Serialize)]
90#[serde(rename_all = "camelCase")]
91pub struct ManifestVerifyFailedSignedPayload<'a> {
92 pub hostname: &'a str,
93 pub rollout: Option<&'a str>,
94 pub rollout_id: &'a str,
95 pub reason: &'a str,
96}
97
98#[derive(Debug, Clone, Serialize)]
101#[serde(rename_all = "camelCase")]
102pub struct ManifestMismatchSignedPayload<'a> {
103 pub hostname: &'a str,
104 pub rollout: Option<&'a str>,
105 pub rollout_id: &'a str,
106 pub reason: &'a str,
107}