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
/*
 * Exoscale Public API
 *
 *  Infrastructure automation API, allowing programmatic access to all Exoscale products and services.  The [OpenAPI Specification](http://spec.openapis.org/oas/v3.0.3.html) source of this documentation can be obtained here:  * [JSON format](https://bump.sh/doc/exoscale-api.json) * [YAML format](https://bump.sh/doc/exoscale-api.yaml)
 *
 * The version of the OpenAPI document: 2.0.0
 * Contact: api@exoscale.com
 * Generated by: https://openapi-generator.tech
 */

#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
pub struct StartInstanceRequest {
    /// Boot in Rescue Mode, using named profile (supported: netboot, netboot-efi)
    #[serde(rename = "rescue-profile", skip_serializing_if = "Option::is_none")]
    pub rescue_profile: Option<RescueProfile>,
}

impl StartInstanceRequest {
    pub fn new() -> StartInstanceRequest {
        StartInstanceRequest {
            rescue_profile: None,
        }
    }
}

/// Boot in Rescue Mode, using named profile (supported: netboot, netboot-efi)
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum RescueProfile {
    #[serde(rename = "netboot-efi")]
    NetbootEfi,
    #[serde(rename = "netboot")]
    Netboot,
}

impl Default for RescueProfile {
    fn default() -> RescueProfile {
        Self::NetbootEfi
    }
}