[Ingest] Per-source proxy toggle instead of one global switch
Each ingestion source now decides independently whether to route through the proxy: added TelegramUseProxy/BaleUseProxy/DivarUseProxy/MedjobsUseProxy/WebsitesUseProxy flags (migration). ScrapeHttpClients.For(s, useProxy) takes the source's own flag; a source is proxied only when its flag is on AND a proxy URL is set. Settings 'sources' tab: removed the global enable checkbox, kept the proxy address field, and added an «از پروکسی استفاده شود» checkbox under each source. Old IngestProxyEnabled column kept for compatibility but no longer gates routing. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -66,6 +66,9 @@ namespace JobsMedical.Web.Migrations
|
||||
b.Property<bool>("BaleEnabled")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<bool>("BaleUseProxy")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<bool>("DemoMode")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
@@ -80,6 +83,9 @@ namespace JobsMedical.Web.Migrations
|
||||
.HasMaxLength(2000)
|
||||
.HasColumnType("character varying(2000)");
|
||||
|
||||
b.Property<bool>("DivarUseProxy")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<int>("IngestIntervalMinutes")
|
||||
.HasColumnType("integer");
|
||||
|
||||
@@ -96,6 +102,9 @@ namespace JobsMedical.Web.Migrations
|
||||
b.Property<int>("MedjobsMaxAds")
|
||||
.HasColumnType("integer");
|
||||
|
||||
b.Property<bool>("MedjobsUseProxy")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<int>("Mode")
|
||||
.HasColumnType("integer");
|
||||
|
||||
@@ -128,6 +137,9 @@ namespace JobsMedical.Web.Migrations
|
||||
b.Property<bool>("TelegramEnabled")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<bool>("TelegramUseProxy")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<DateTime>("UpdatedAt")
|
||||
.HasColumnType("timestamp with time zone");
|
||||
|
||||
@@ -153,6 +165,9 @@ namespace JobsMedical.Web.Migrations
|
||||
b.Property<bool>("WebsitesEnabled")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.Property<bool>("WebsitesUseProxy")
|
||||
.HasColumnType("boolean");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.ToTable("AppSettings");
|
||||
|
||||
Reference in New Issue
Block a user