57 lines
1.9 KiB
C#
57 lines
1.9 KiB
C#
namespace SharpAbp.Infrastructure.Api.Configuration
|
|
{
|
|
public class JwtConfig
|
|
{
|
|
public string TokenKey { get; set; } = "token";
|
|
public string Issuer { get; set; } = "admin";
|
|
public string Audience { get; set; } = "";
|
|
public string SecretKey { get; set; } = "";
|
|
public bool ValidateIssuer { get; set; } = false;
|
|
public bool ValidateAudience { get; set; } = false;
|
|
public bool ValidateIssuerSigningKey { get; set; } = false;
|
|
public bool ValidateLifetime { get; set; } = false;
|
|
}
|
|
|
|
public class CapConfig
|
|
{
|
|
public string Host { get; set; } = "localhost";
|
|
public string UserName { get; set; } = "admin";
|
|
public string Password { get; set; } = "";
|
|
public string VirtualHost { get; set; } = "/";
|
|
public string PGLogHost { get; set; } = "";
|
|
}
|
|
|
|
public class RedisConfig
|
|
{
|
|
public string Host { get; set; } = "localhost";
|
|
public int Port { get; set; } = 6379;
|
|
public string UserName { get; set; } = "";
|
|
public string Password { get; set; } = "";
|
|
public int Database { get; set; } = 0;
|
|
}
|
|
|
|
public class WXConfig
|
|
{
|
|
public string AppId { get; set; } = "";
|
|
public string Secret { get; set; } = "";
|
|
public string Url { get; set; } = "";
|
|
}
|
|
|
|
public class AppSettings
|
|
{
|
|
public JwtConfig JwtConfig { get; set; } = new();
|
|
public string PgSqlConnection { get; set; } = "";
|
|
public CapConfig CapConfig { get; set; } = new();
|
|
public RedisConfig RedisConfig { get; set; } = new();
|
|
public MongoDbSettings MongoDbSettings { get; set; } = new();
|
|
public WXConfig WXConfig { get; set; } = new();
|
|
}
|
|
|
|
public class MongoDbSettings
|
|
{
|
|
public string Username { get; set; } = "";
|
|
public string Password { get; set; } = "";
|
|
public string ServerUrl { get; set; } = "";
|
|
}
|
|
}
|