UNPKG

@topgroup/diginext

Version:

A BUILD SERVER & CLI to deploy apps to any Kubernetes clusters.

101 lines 2.19 kB
import path from "path"; export type PostgresConnectionInfo = { /** * Connection string */ url?: string; /** * Database name * @default admin */ dbName?: string; /** * @default admin */ authDb?: string; host: string; /** * @default 5432 */ port?: string; /** * @default root */ user?: string; pass: string; }; export declare const getConnectionString: (options: Partial<PostgresConnectionInfo>) => string; export declare const checkConnection: (options: PostgresConnectionInfo & { isDebugging?: boolean; }) => Promise<boolean>; export declare const backup: (options: Partial<PostgresConnectionInfo> & { /** * @default admin */ authDb?: string; /** * Output directory */ outDir?: string; } & { isDebugging?: boolean; }) => Promise<{ name: string; path: string; }>; export declare const restore: (options: Partial<PostgresConnectionInfo> & { /** * Database name * @default "all-databases" */ dbName?: string; /** * @default admin */ authDb?: string; /** * Path to backup ".dump" */ path?: string; } & { isDebugging?: boolean; }) => Promise<boolean>; declare const PostgreSQL: { checkConnection: (options: PostgresConnectionInfo & { isDebugging?: boolean; }) => Promise<boolean>; backup: (options: Partial<PostgresConnectionInfo> & { /** * @default admin */ authDb?: string; /** * Output directory */ outDir?: string; } & { isDebugging?: boolean; }) => Promise<{ name: string; path: string; }>; restore: (options: Partial<PostgresConnectionInfo> & { /** * Database name * @default "all-databases" */ dbName?: string; /** * @default admin */ authDb?: string; /** * Path to backup ".dump" */ path?: string; } & { isDebugging?: boolean; }) => Promise<boolean>; }; export default PostgreSQL; //# sourceMappingURL=pg.d.ts.map