polyv-live-cli
Version:
CLI tool for managing PolyV live streaming services.
67 lines • 2.16 kB
TypeScript
import { AccountsStore } from '../types/account.types';
export interface IntegrityCheckResult {
isValid: boolean;
message: string;
issues: ConfigurationIssue[];
validationDetails: {
fileAccessible: boolean;
validJson: boolean;
validStructure: boolean;
validEncryption: boolean;
securePermissions: boolean;
};
}
export interface ConfigurationIssue {
type: 'file_access' | 'json_format' | 'structure' | 'encryption' | 'permissions' | 'version';
severity: 'critical' | 'warning' | 'info';
description: string;
suggestedFix: string;
autoFixable: boolean;
}
export interface RecoveryStrategy {
id: string;
name: string;
description: string;
steps: string[];
riskLevel: 'low' | 'medium' | 'high';
dataPreservation: 'full' | 'partial' | 'none';
}
export interface RecoveryResult {
success: boolean;
message: string;
strategyUsed: string;
stepsExecuted: string[];
warnings: string[];
recoveredConfig?: AccountsStore;
backupFile?: string;
}
export interface BackupInfo {
path: string;
createdAt: string;
size: number;
isValid: boolean;
version?: string;
}
export declare class ConfigRecoveryManager {
private versionManager;
private permissionManager;
constructor();
checkIntegrity(configPath: string): IntegrityCheckResult;
private validateConfigStructure;
private validateEncryptionData;
getRecoveryStrategies(integrityResult: IntegrityCheckResult): RecoveryStrategy[];
executeRecovery(strategyId: string, configPath: string, options?: {
backupPath?: string;
newMasterKey?: string;
}): RecoveryResult;
private executeAutoFix;
private executeBackupRestore;
private executeManualFix;
private executeRecreate;
private executeKeyRecovery;
findBackupFiles(configPath: string): BackupInfo[];
createBackup(configPath: string): string | null;
getRecoveryGuidance(integrityResult: IntegrityCheckResult): string[];
}
export declare const defaultConfigRecoveryManager: ConfigRecoveryManager;
//# sourceMappingURL=config-recovery-manager.d.ts.map