1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
/*
* Windmill API
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.684.0
* Contact: contact@windmill.dev
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct VaultSettings {
/// HashiCorp Vault server address (e.g., https://vault.company.com:8200)
#[serde(rename = "address")]
pub address: String,
/// KV v2 secrets engine mount path (e.g., windmill)
#[serde(rename = "mount_path")]
pub mount_path: String,
/// Vault JWT auth role name for Windmill (optional, if not provided token auth is used)
#[serde(rename = "jwt_role", skip_serializing_if = "Option::is_none")]
pub jwt_role: Option<String>,
/// Vault Enterprise namespace (optional)
#[serde(rename = "namespace", skip_serializing_if = "Option::is_none")]
pub namespace: Option<String>,
/// Static Vault token for testing/development (optional, if provided this is used instead of JWT authentication)
#[serde(rename = "token", skip_serializing_if = "Option::is_none")]
pub token: Option<String>,
/// Skip TLS certificate verification when connecting to Vault. Only use for self-signed certificates in development environments.
#[serde(rename = "skip_ssl_verify", skip_serializing_if = "Option::is_none")]
pub skip_ssl_verify: Option<bool>,
}
impl VaultSettings {
pub fn new(address: String, mount_path: String) -> VaultSettings {
VaultSettings {
address,
mount_path,
jwt_role: None,
namespace: None,
token: None,
skip_ssl_verify: None,
}
}
}