refacto site settings
Some checks failed
Dotnet build and test / build (pull_request) Failing after 8m29s

This commit is contained in:
Paul Schneider 2026-09-17 22:22:18 +01:00
commit 3bc4142383
Signed by: notazof
GPG key ID: 1DD5D838E5343B06
33 changed files with 399 additions and 315 deletions

View file

@ -6,89 +6,72 @@ namespace Yavsc
{
public class SiteSettings
{
public string Title { get; set; } = "Yavsc";
public string Title { get; set; }
public string Slogan { get; set; } = "";
public string Banner { get; set; } = "";
public string Slogan { get; set; }
public string Banner { get; set; }
public string StyleSheet { get; set; } = "site.css";
public string FavIcon { get; set; } = "favicon.ico";
public string Logo { get; set; } = "logo.png";
public string StyleSheet { get; set; }
public string FavIcon { get; set; }
public string Logo { get; set; }
/// <summary>
/// Origins to allow via the CORS "default" policy.
/// Each entry must be a full origin (scheme + host [+ port]), e.g. "https://app.example.com".
/// </summary>
public IList<string> CorsAllowedOrigins { get; set; } = new List<string>
{
"https://localhost:5001"
};
public IList<string> CorsAllowedOrigins { get; set; }
/// <summary>
/// External Url
/// </summary>
/// <value></value>
public string ExternalUrl { get; set; } = "http://lua.pschneider.fr";
public string ExternalUrl { get; set; }
/// <summary>
/// Base URL of the API fronting this site.
/// </summary>
public string ApiUrl { get; set; } = "";
public string ApiUrl { get; set; }
/// <summary>
/// Must be a fqdn.
/// </summary>
/// <returns></returns>
public string Authority { get; set; } = "lua.pschneider.fr";
public string Authority { get; set; }
/// <summary>
/// Owner's email
/// </summary>
/// <returns></returns>
public StaticContact Owner { get; set; } = new StaticContact
{
EMail = "root@lua.pschneider.fr",
Name = "Root"
} ;
public StaticContact Owner { get; set; }
/// <summary>
/// Administrator's email
/// </summary>
/// <returns></returns>
public StaticContact Admin { get; set; } = new StaticContact
{
EMail = "root@lua.pschneider.fr",
Name = "Root"
} ;
public StaticContact Admin { get; set; }
public string DataDir { get; set; } = "data";
public string Avatars { get; set; } = "avatars";
public string DataDir { get; set; }
public string Avatars { get; set; }
public long Quota { get; set; }
public string Blog { get; set; } = "blogs";
public string Bills { get; set; } = "bills";
public string GitRepository { get; set; } = "sources";
public string Blog { get; set; }
public string Bills { get; set; }
public string GitRepository { get; set; }
public string BusinessName { get; set; } = "Yavsc";
public string? Street { get; set; }
public string? PostalCode { get; set; }
public string? CountryCode { get; set; }
public string HomeViewName { get; set; } = "Home";
/// <summary>
/// Specifies the directory where should be
/// generated pdf files using pandoc
/// </summary>
/// <returns>The temporary directory to use</returns>
public string TempDir { get; set; } = "temp";
public string TempDir { get; set; }
/// <summary>
/// Disk usage user list maximum length in memory
/// </summary>
/// <value></value>
public int DUUserListLen { get; set; } = 256;
public int DUUserListLen { get; set; }
/// <summary>
/// Default acl file name
/// </summary>
/// <value></value>
public string AccessListFileName { get; set; } = ".access";
public string AccessListFileName { get; set; }
}
}