api: add default property to domain list
This commit is contained in:
parent
73b40e9b46
commit
879546aff6
|
@ -23,6 +23,10 @@ use crate::api2::types::*;
|
||||||
schema: SINGLE_LINE_COMMENT_SCHEMA,
|
schema: SINGLE_LINE_COMMENT_SCHEMA,
|
||||||
optional: true,
|
optional: true,
|
||||||
},
|
},
|
||||||
|
default: {
|
||||||
|
description: "Default realm.",
|
||||||
|
type: bool,
|
||||||
|
}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -33,7 +37,7 @@ use crate::api2::types::*;
|
||||||
/// box (before the user is authenticated).
|
/// box (before the user is authenticated).
|
||||||
fn list_domains() -> Result<Value, Error> {
|
fn list_domains() -> Result<Value, Error> {
|
||||||
let mut list = Vec::new();
|
let mut list = Vec::new();
|
||||||
list.push(json!({ "realm": "pam", "comment": "Linux PAM standard authentication" }));
|
list.push(json!({ "realm": "pam", "comment": "Linux PAM standard authentication", "default": true }));
|
||||||
list.push(json!({ "realm": "pbs", "comment": "Proxmox Backup authentication server" }));
|
list.push(json!({ "realm": "pbs", "comment": "Proxmox Backup authentication server" }));
|
||||||
Ok(list.into())
|
Ok(list.into())
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue