1 |
use schemars::JsonSchema; |
2 |
use serde::{Deserialize, Serialize}; |
3 |
use std::net::IpAddr; |
4 |
use std::path::PathBuf; |
5 |
use uuid::Uuid; |
6 |
|
7 |
#[derive(Serialize, Deserialize, JsonSchema, Debug)] |
8 |
pub struct UpdateConf { |
9 |
pub address: Option<IpAddr>, |
10 |
pub port: Option<u16>, |
11 |
} |
12 |
|
13 |
#[derive(Serialize, Deserialize, JsonSchema, Debug)] |
14 |
pub struct StdinBuffer { |
15 |
pub stdin: String, |
16 |
pub endl: Option<bool>, |
17 |
} |
18 |
|
19 |
#[derive(Serialize, Deserialize, JsonSchema, Debug)] |
20 |
pub struct ServicePath { |
21 |
pub service_uuid: Uuid, |
22 |
} |
23 |
|
24 |
#[derive(Serialize, Deserialize, JsonSchema, Debug)] |
25 |
pub struct NewService { |
26 |
pub name: Option<String>, |
27 |
pub command: Option<String>, |
28 |
pub args: Option<Option<String>>, |
29 |
pub directory: Option<Option<PathBuf>>, |
30 |
pub autostart: Option<bool>, |
31 |
} |