1
0
Fork 0
mirror of https://codeberg.org/icewind/haze.git synced 2026-06-03 09:04:12 +02:00

enable auto setup by default

This commit is contained in:
Robin Appelman 2026-01-19 18:39:39 +01:00
commit 44ae8ebae5
2 changed files with 6 additions and 1 deletions

View file

@ -272,7 +272,7 @@ sources_root = "/path/to/sources" # path of the nextcloud sources. required
work_dir = "/path/to/temp/dir" # path to temporary directory. optional, defaults to "/tmp/haze"
[auto_setup] # optional
enabled = false # whether or not to automatically install nextcloud on `haze start`. optional, defaults to false
enabled = false # whether or not to automatically install nextcloud on `haze start`. enabled by default
username = "foo" # username for admin user during auto setup. optional, defaults to "admin"
password = "bar" # password for admin user during auto setup. optional, defaults to "admin"
post_setup = [# commands to execute after setup, defaults to []

View file

@ -63,6 +63,7 @@ impl From<RawHazeConfig> for HazeConfig {
#[derive(Debug, Deserialize)]
pub struct HazeAutoSetupConfig {
#[serde(default = "default_auto_setup")]
pub enabled: bool,
#[serde(default = "default_auto_setup_username")]
pub username: String,
@ -87,6 +88,10 @@ fn default_work_dir() -> Utf8PathBuf {
"/tmp/haze".into()
}
fn default_auto_setup() -> bool {
true
}
fn default_auto_setup_username() -> String {
"admin".to_string()
}