feat: load form api settings

This commit is contained in:
Aravinth Manivannan 2022-12-29 16:40:06 +05:30
parent 088088c91e
commit e819cf850a
Signed by: realaravinth
GPG Key ID: AD9F0F08E855ED88
2 changed files with 11 additions and 0 deletions

View File

@ -38,3 +38,7 @@ password = "password"
name = "postgres"
pool = 4
database_type="postgres" # "postgres"
[form]
api_key = "longrandomlygeneratedpassword"
url = "http://localhost:6000"

View File

@ -83,6 +83,7 @@ pub struct Settings {
pub database: Database,
pub page: PageConfig,
pub conductors: Vec<Conductor>,
pub form: Forms,
}
#[derive(Debug, Clone, Serialize, Deserialize)]
@ -92,6 +93,12 @@ pub struct Conductor {
pub url: Url,
}
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct Forms {
pub api_key: String,
pub url: Url,
}
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct PageConfig {
pub base_path: String,