tembo_api_client/models/
volume_mount.rs

1/*
2 * Tembo Cloud
3 *
4 * Platform API for Tembo Cloud             </br>             </br>             To find a Tembo Data API, please find it here:             </br>             </br>             [AWS US East 1](https://api.data-1.use1.tembo.io/swagger-ui/)
5 *
6 * The version of the OpenAPI document: v1.0.0
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use serde::{Deserialize, Serialize};
12
13#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
14pub struct VolumeMount {
15    #[serde(rename = "mount_path")]
16    pub mount_path: Option<String>,
17    #[serde(
18        rename = "mount_propagation",
19        default,
20        with = "::serde_with::rust::double_option",
21        skip_serializing_if = "Option::is_none"
22    )]
23    pub mount_propagation: Option<Option<String>>,
24    #[serde(rename = "name")]
25    pub name: String,
26    #[serde(
27        rename = "read_only",
28        default,
29        with = "::serde_with::rust::double_option",
30        skip_serializing_if = "Option::is_none"
31    )]
32    pub read_only: Option<Option<bool>>,
33    #[serde(
34        rename = "sub_path",
35        default,
36        with = "::serde_with::rust::double_option",
37        skip_serializing_if = "Option::is_none"
38    )]
39    pub sub_path: Option<Option<String>>,
40    #[serde(
41        rename = "sub_path_expr",
42        default,
43        with = "::serde_with::rust::double_option",
44        skip_serializing_if = "Option::is_none"
45    )]
46    pub sub_path_expr: Option<Option<String>>,
47}
48
49impl VolumeMount {
50    pub fn new(mount_path: String, name: String) -> VolumeMount {
51        VolumeMount {
52            mount_path: Some(mount_path),
53            mount_propagation: None,
54            name,
55            read_only: None,
56            sub_path: None,
57            sub_path_expr: None,
58        }
59    }
60}