Требования:
- postgresql
- .net 6
- nodejs
Настройка:
- В
SdHub/appsettings.Development.jsonподредактировать connection string'и дляDatabaseиHangfire - БД для
Hangfireнужно создать руками, основная БД создасться и засидиться сама если есть права - Серты для подписи жвт для dev окружения есть в репо, если нужно то новые можно сгенерировать скриптом в
/scripts
Запуск:
- Экспортировать
ASPNETCORE_ENVIRONMENTс значениемDevelopmentили указать в профиле для студии - Запустить
SdHubиз солюшена в/Server - Запустить
npm run startиз/Client - Открыть http://localhost:5790 и войти с кредсами
Admin:strong_passwd
| name | default | summary |
|---|---|---|
| AppInfo | Application info | |
| BaseUrl* | Base url | |
| GitRefName* | "not_set" | Git ref. Fill from env if docker container |
| GitCommitSha* | "deadbeef" | Git sha. Fill from env if docker container |
| FrontDevServer | Use angular dev server instead compiled blobs. For development | |
| DisableUsersRegistration | true | Disable user registration |
| Database | Main db options | |
| ConnectionString* | "" | Connection string |
| FileProcessor | Files processings options | |
| CacheDir* | "./cache/upload" | Directory for temp files |
| PreserveCache | false | Don't delete cache |
| Hangfire | Hangfire scheduler options. GUI on /hgf | |
| DatabaseConnectionString* | Database connection string | |
| DatabaseSchema* | "public" | Database schema |
| RunServer | true | Run hangfire worker on backend |
| ServerName* | "bakend" | Worker name |
| Mailing | Mailing options | |
| From* | Sender email | |
| Host* | Mail server host | |
| Port | 587 | Mail server port |
| Username* | Login | |
| Password* | Password | |
| EnableSsl | true | Enable ssl |
| UseMaildir | true | Использовать Maildir вместо отправки сообщений по сети |
| PathToMaildir* | "./maildir/" | Путь до корневой папки Maildir |
| MailTrustLevel | "Allow" | Есть установить то email'ы не будут проверяться на однодневки/подозрительные |
| TemplatesDir* | "./files/mailing/templates" | Templates directory |
| Recaptcha | Google recaptcha options | |
| Bypass | true | Disable captcha |
| SecretKey* | Secret key | |
| SiteKey* | Public site key | |
| SdHubSeeder | Database seeder options | |
| AdminPassword* | Password for Admin account | |
| Swagger | Swagger options | |
| Enable | false | Enable /swagger endpoint |
| WebSecurity | Web security options | |
| EnableHttpsRedirections | true | Enable https redirection |
| EnableForwardedHeaders | true | Enable forwarded headers like X-Forwarded-For |
| Jwt | {} | Jwt auth options |
| Issuers* | ["SdHub"] | Issuers |
| Issuer* | "SdHub" | Issuer |
| Audiences* | ["SdHub"] | Audiences |
| ValidateLifetime | true | Validate lifetime |
| JwtLifetime | "00:05:00" | Lifetime |
| RefreshTokenLifetime | "5.00:00:00" | Refresh token lifetime |
| PfxPassword | Password for pfx cert. Can be null if not required | |
| PfxFile* | Path to pfx cert file | |
| LogPii | false | Log more info about authorization |
| Cors | {} | CORS options |
| AllowedHosts* | [] | Allowed hosts |
| Serilog | Options for logging to ES. Used serilogs-sink-{assemblyName}-{0:yyyy.MM.dd} index | |
| DisableElastic | true | Disable logging to elastic search |
| ElasticUris* | [] | Urls to ES cluster |
| ElasticIndexPrefix | Append {prefix}- to index | |
| LevelPreset | "Prod" | Predefined levels for logging AddCustomSerilog |
| EnableRequestLogging | true | Enable request logging |
| RequestLogMessageLevel | "Information" | Request message log level |