feat(netflow): автоматизировать настройку туннеля коллектора
This commit is contained in:
1 parent
fcca92706b
commit
db81cf0f97
33 files changed
+1503
-22
No files matched your search
@@ -9,6 +9,23 @@ export const flowHostPeerSchema = z.object({
|
||||
endpoint: z.string().optional(),
|
||||
})
|
||||
|
||||
export const trafficFlowHostStatusSchema = z.object({
|
||||
configured: z.boolean(),
|
||||
reachable: z.boolean(),
|
||||
interfaceUp: z.boolean(),
|
||||
configMatches: z.boolean().nullable(),
|
||||
publicKey: z.string(),
|
||||
listenPort: z.number().int().nonnegative(),
|
||||
addresses: z.array(z.string()),
|
||||
peers: z.array(z.object({
|
||||
publicKey: z.string(), allowedIps: z.array(z.string()),
|
||||
lastHandshakeAt: z.number().int().nonnegative().nullable(),
|
||||
receivedBytes: z.number().nonnegative(), sentBytes: z.number().nonnegative(),
|
||||
})),
|
||||
error: z.string().nullable(),
|
||||
})
|
||||
export type TrafficFlowHostStatus = z.infer<typeof trafficFlowHostStatusSchema>
|
||||
|
||||
export const trafficFlowSettingsDtoSchema = z.object({
|
||||
enabled: z.boolean(),
|
||||
collectorIp: z.string().min(1),
|
||||
@@ -77,6 +94,9 @@ export const trafficFlowOverlayResultSchema = z.object({
|
||||
trafficFlow: z.boolean(),
|
||||
steps: z.array(z.string()),
|
||||
hostFiles: z.array(trafficFlowHostFileSchema),
|
||||
hostStatus: trafficFlowHostStatusSchema.optional(),
|
||||
stage: z.enum(["manual", "host-pending", "applied"]).optional(),
|
||||
hostError: z.string().optional(),
|
||||
})
|
||||
|
||||
export const flowTalkerDtoSchema = z.object({
|
||||
|
||||
Reference in new issue
Block a user