Introduced a new `verify_tls` boolean option in health check configurations across various services, allowing users to specify whether to validate TLS certificates during health checks. Updated related components and services to accommodate this new option, ensuring proper handling in both the backend and frontend. Enhanced tests to validate the new functionality and ensure correct behavior with different configurations.
43 lines
1.2 KiB
TypeScript
43 lines
1.2 KiB
TypeScript
import { z } from "zod";
|
|
|
|
export const cfdmBindingSyncItemSchema = z.object({
|
|
bindingId: z.number().int().positive(),
|
|
serviceId: z.number().int().positive(),
|
|
serviceName: z.string().min(1),
|
|
serviceSlug: z.string().min(1),
|
|
fqdn: z.string().min(1),
|
|
zoneName: z.string().min(1),
|
|
hostname: z.string(),
|
|
ips: z.array(z.string()),
|
|
deleted: z.boolean().optional(),
|
|
});
|
|
|
|
export const cfdmSyncBindingsBodySchema = z.object({
|
|
bindings: z.array(cfdmBindingSyncItemSchema).min(1),
|
|
});
|
|
|
|
export type CfdmBindingSyncItem = z.infer<typeof cfdmBindingSyncItemSchema>;
|
|
|
|
export const appSettingsPatchSchema = z.object({
|
|
vpsTrackerUrl: z.string().url().or(z.literal("")).optional(),
|
|
vpsTrackerIntegrationToken: z.string().optional(),
|
|
vpsTrackerSyncEnabled: z.boolean().optional(),
|
|
showQuickActions: z.boolean().optional(),
|
|
});
|
|
|
|
export type AppSettingsPatch = z.infer<typeof appSettingsPatchSchema>;
|
|
|
|
export const vpsTrackerEventSchema = z.object({
|
|
event: z.enum(["vps_down", "vps_up"]),
|
|
vps: z.array(
|
|
z.object({
|
|
id: z.string().min(1),
|
|
ip: z.string().optional(),
|
|
label: z.string().optional(),
|
|
}),
|
|
),
|
|
timestamp: z.string().datetime().optional(),
|
|
});
|
|
|
|
export type VpsTrackerEvent = z.infer<typeof vpsTrackerEventSchema>;
|