feat(rust): scaffold Rust workspace and fix TypeScript build errors
- Add @git.zone/tsrust with linux_amd64/linux_arm64 cross-compilation - Scaffold Rust workspace with 5 crates: mailer-core, mailer-smtp, mailer-security, mailer-napi, mailer-bin - Fix all TypeScript compilation errors for upgraded dependencies (smartfile v13, mailauth v4.13, smartproxy v23) - Replace smartfile.fs/memory with @push.rocks/smartfs throughout codebase - Fix .ts import extensions to .js for NodeNext module resolution - Update DKIMSignOptions usage to match mailauth v4.13 API - Add MTA error classes with permissive signatures for legacy SMTP client - Replace removed DcRouter/StorageManager/deliverability imports with local interfaces
This commit is contained in:
@@ -1,8 +1,18 @@
|
||||
import * as plugins from '../../plugins.ts';
|
||||
import type { IEmailDomainConfig } from './interfaces.ts';
|
||||
import { logger } from '../../logger.ts';
|
||||
import type { DcRouter } from '../../classes.dcrouter.ts';
|
||||
import type { StorageManager } from '../../storage/index.ts';
|
||||
import * as plugins from '../../plugins.js';
|
||||
import type { IEmailDomainConfig } from './interfaces.js';
|
||||
import { logger } from '../../logger.js';
|
||||
/** External DcRouter interface shape used by DnsManager */
|
||||
interface IDcRouterLike {
|
||||
storageManager: IStorageManagerLike;
|
||||
dnsServer?: any;
|
||||
options?: { dnsNsDomains?: string[]; dnsScopes?: string[] };
|
||||
}
|
||||
|
||||
/** External StorageManager interface shape used by DnsManager */
|
||||
interface IStorageManagerLike {
|
||||
get(key: string): Promise<string | null>;
|
||||
set(key: string, value: string): Promise<void>;
|
||||
}
|
||||
|
||||
/**
|
||||
* DNS validation result
|
||||
@@ -30,10 +40,10 @@ interface IDnsRecords {
|
||||
* Handles both validation and creation of DNS records
|
||||
*/
|
||||
export class DnsManager {
|
||||
private dcRouter: DcRouter;
|
||||
private storageManager: StorageManager;
|
||||
private dcRouter: IDcRouterLike;
|
||||
private storageManager: IStorageManagerLike;
|
||||
|
||||
constructor(dcRouter: DcRouter) {
|
||||
constructor(dcRouter: IDcRouterLike) {
|
||||
this.dcRouter = dcRouter;
|
||||
this.storageManager = dcRouter.storageManager;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user