@serve.zone/dcrouter 13.17.8 → 13.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -42707,7 +42707,7 @@ Customer Support Team`}};async onActivate(b){this.appui=b.appui,this.appui.setCo
42707
42707
  <!-- Backend Protocols Section -->
42708
42708
  ${this.renderBackendProtocols()}
42709
42709
  </div>
42710
- `}formatNumber(a){return a>=1e6?(a/1e6).toFixed(1)+"M":a>=1e3?(a/1e3).toFixed(1)+"K":a.toFixed(0)}formatBytes(a){let r=["B","KB","MB","GB"],s=a,o=0;for(;s>=1024&&o<r.length-1;)s/=1024,o++;return`${s.toFixed(1)} ${r[o]}`}formatBitsPerSecond(a){let r=a*8,s=["bit/s","kbit/s","Mbit/s","Gbit/s"],o=r,n=0;for(;o>=1e3&&n<s.length-1;)o/=1e3,n++;return`${o.toFixed(1)} ${s[n]}`}calculateThroughput(){return{in:this.networkState.throughputRate.bytesInPerSecond,out:this.networkState.throughputRate.bytesOutPerSecond}}renderNetworkStats(){let a=this.networkState.requestsPerSecond||0,r=this.calculateThroughput(),s=this.statsState.serverStats?.activeConnections||0,o=[...this.requestsPerSecHistory];for(;o.length<20;)o.unshift(0);let n=[{id:"connections",title:"Active Connections",value:s,type:"number",icon:"lucide:Plug",color:s>100?"#f59e0b":"#22c55e",description:`Total: ${this.networkState.requestsTotal||this.statsState.serverStats?.totalConnections||0}`,actions:[{name:"View Details",iconName:"fa:magnifyingGlass",action:i(async()=>{},"action")}]},{id:"requests",title:"Requests/sec",value:a,type:"trend",icon:"lucide:ChartLine",color:"#3b82f6",trendData:o,description:`Total: ${this.formatNumber(this.networkState.requestsTotal||0)} requests`},{id:"throughputIn",title:"Throughput In",value:this.formatBitsPerSecond(r.in),unit:"",type:"number",icon:"lucide:Download",color:"#22c55e",description:`Total: ${this.formatBytes(this.networkState.totalBytes?.in||0)}`},{id:"throughputOut",title:"Throughput Out",value:this.formatBitsPerSecond(r.out),unit:"",type:"number",icon:"lucide:Upload",color:"#8b5cf6",description:`Total: ${this.formatBytes(this.networkState.totalBytes?.out||0)}`}];return w`
42710
+ `}formatNumber(a){return a>=1e6?(a/1e6).toFixed(1)+"M":a>=1e3?(a/1e3).toFixed(1)+"K":a.toFixed(0)}formatBytes(a){let r=["B","KB","MB","GB"],s=a,o=0;for(;s>=1024&&o<r.length-1;)s/=1024,o++;return`${s.toFixed(1)} ${r[o]}`}formatBitsPerSecond(a){let r=a*8,s=["bit/s","kbit/s","Mbit/s","Gbit/s"],o=r,n=0;for(;o>=1e3&&n<s.length-1;)o/=1e3,n++;return`${o.toFixed(1)} ${s[n]}`}calculateThroughput(){return{in:this.networkState.throughputRate.bytesInPerSecond,out:this.networkState.throughputRate.bytesOutPerSecond}}renderNetworkStats(){let a=this.networkState.requestsPerSecond||0,r=this.calculateThroughput(),s=this.statsState.serverStats?.activeConnections||0,o=[...this.requestsPerSecHistory];for(;o.length<20;)o.unshift(0);let n=[{id:"connections",title:"Active Connections",value:s,type:"number",icon:"lucide:Plug",color:s>100?"#f59e0b":"#22c55e",description:`Total: ${this.formatNumber(this.statsState.serverStats?.totalConnections||0)} connections`,actions:[{name:"View Details",iconName:"fa:magnifyingGlass",action:i(async()=>{},"action")}]},{id:"requests",title:"Requests/sec",value:a,type:"trend",icon:"lucide:ChartLine",color:"#3b82f6",trendData:o,description:`Total: ${this.formatNumber(this.networkState.requestsTotal||0)} requests`},{id:"throughputIn",title:"Throughput In",value:this.formatBitsPerSecond(r.in),unit:"",type:"number",icon:"lucide:Download",color:"#22c55e",description:`Total: ${this.formatBytes(this.networkState.totalBytes?.in||0)}`},{id:"throughputOut",title:"Throughput Out",value:this.formatBitsPerSecond(r.out),unit:"",type:"number",icon:"lucide:Upload",color:"#8b5cf6",description:`Total: ${this.formatBytes(this.networkState.totalBytes?.out||0)}`}];return w`
42711
42711
  <dees-statsgrid
42712
42712
  .tiles=${n}
42713
42713
  .minTileWidth=${200}
@@ -46314,4 +46314,4 @@ ibantools/jsnext/ibantools.js:
46314
46314
  * @preferred
46315
46315
  *)
46316
46316
  */
46317
- //# sourceMappingURL=bundle-1776129443770.js.map
46317
+ //# sourceMappingURL=bundle-1776172354484.js.map
@@ -3,7 +3,7 @@
3
3
  */
4
4
  export const commitinfo = {
5
5
  name: '@serve.zone/dcrouter',
6
- version: '13.17.8',
6
+ version: '13.18.0',
7
7
  description: 'A multifaceted routing service handling mail and SMS delivery functions.'
8
8
  };
9
9
  //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMDBfY29tbWl0aW5mb19kYXRhLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vdHMvMDBfY29tbWl0aW5mb19kYXRhLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBQ0gsTUFBTSxDQUFDLE1BQU0sVUFBVSxHQUFHO0lBQ3hCLElBQUksRUFBRSxzQkFBc0I7SUFDNUIsT0FBTyxFQUFFLFNBQVM7SUFDbEIsV0FBVyxFQUFFLDBFQUEwRTtDQUN4RixDQUFBIn0=
@@ -1,6 +1,6 @@
1
1
  import * as plugins from './plugins.js';
2
2
  import * as paths from './paths.js';
3
- import { UnifiedEmailServer, type IUnifiedEmailServerOptions, type IEmailRoute } from '@push.rocks/smartmta';
3
+ import { UnifiedEmailServer, type IUnifiedEmailServerOptions, type IEmailRoute, type IStorageManagerLike } from '@push.rocks/smartmta';
4
4
  import { CertProvisionScheduler } from './classes.cert-provision-scheduler.js';
5
5
  import { DcRouterDb, CacheCleaner } from './db/index.js';
6
6
  import { OpsServer } from './opsserver/index.js';
@@ -12,7 +12,7 @@ import { RouteConfigManager, ApiTokenManager, ReferenceResolver, TargetProfileMa
12
12
  import { type IHttp3Config } from './http3/index.js';
13
13
  import { DnsManager } from './dns/manager.dns.js';
14
14
  import { AcmeConfigManager } from './acme/manager.acme-config.js';
15
- import { EmailDomainManager } from './email/classes.email-domain.manager.js';
15
+ import { EmailDomainManager } from './email/index.js';
16
16
  export interface IDcRouterOptions {
17
17
  /** Base directory for all dcrouter data. Defaults to ~/.serve.zone/dcrouter */
18
18
  baseDir?: string;
@@ -211,7 +211,8 @@ export declare class DcRouter {
211
211
  radiusServer?: RadiusServer;
212
212
  opsServer: OpsServer;
213
213
  metricsManager?: MetricsManager;
214
- storageManager: any;
214
+ private emailEventSubscriptions;
215
+ storageManager: IStorageManagerLike;
215
216
  dcRouterDb?: DcRouterDb;
216
217
  cacheCleaner?: CacheCleaner;
217
218
  remoteIngressManager?: RemoteIngressManager;
@@ -347,8 +348,7 @@ export declare class DcRouter {
347
348
  */
348
349
  private generateEmailDnsRecords;
349
350
  /**
350
- * Load DKIM records from JSON files
351
- * Reads all *.dkimrecord.json files from the DNS records directory
351
+ * Generate DKIM DNS records for internal-dns domains from smartmta's selector-aware DKIM state.
352
352
  */
353
353
  private loadDkimRecords;
354
354
  /**
@@ -369,6 +369,8 @@ export declare class DcRouter {
369
369
  * Apply proxy IP replacement logic to DNS records
370
370
  */
371
371
  private applyProxyIpReplacement;
372
+ private addEmailEventSubscription;
373
+ private clearEmailEventSubscriptions;
372
374
  /**
373
375
  * Detect the server's public IP address
374
376
  */