mirror of
https://github.com/fosrl/pangolin.git
synced 2026-06-08 08:33:14 +00:00
🏷️ fix types imports from a client component
This commit is contained in:
@@ -40,6 +40,7 @@ import { signPublicKey, getOrgCAKeys } from "@server/lib/sshCA";
|
|||||||
import config from "@server/lib/config";
|
import config from "@server/lib/config";
|
||||||
import { sendToClient } from "#private/routers/ws";
|
import { sendToClient } from "#private/routers/ws";
|
||||||
import { ActionsEnum } from "@server/auth/actions";
|
import { ActionsEnum } from "@server/auth/actions";
|
||||||
|
import type { SignSshKeyResponse } from "@server/routers/ssh/types";
|
||||||
|
|
||||||
const paramsSchema = z.strictObject({
|
const paramsSchema = z.strictObject({
|
||||||
orgId: z.string().nonempty()
|
orgId: z.string().nonempty()
|
||||||
@@ -64,23 +65,6 @@ const bodySchema = z
|
|||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
export type SignSshKeyResponse = {
|
|
||||||
certificate?: string;
|
|
||||||
messageIds: number[];
|
|
||||||
messageId?: number;
|
|
||||||
sshUsername: string;
|
|
||||||
sshHost: string;
|
|
||||||
resourceId: number;
|
|
||||||
siteIds: number[];
|
|
||||||
siteId: number;
|
|
||||||
keyId?: string;
|
|
||||||
validPrincipals?: string[];
|
|
||||||
validAfter?: string;
|
|
||||||
validBefore?: string;
|
|
||||||
expiresIn?: number;
|
|
||||||
authDaemonMode: "site" | "remote" | "native" | null;
|
|
||||||
};
|
|
||||||
|
|
||||||
export async function signSshKey(
|
export async function signSshKey(
|
||||||
req: Request,
|
req: Request,
|
||||||
res: Response,
|
res: Response,
|
||||||
|
|||||||
16
server/routers/ssh/types.ts
Normal file
16
server/routers/ssh/types.ts
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
export type SignSshKeyResponse = {
|
||||||
|
certificate?: string;
|
||||||
|
messageIds: number[];
|
||||||
|
messageId?: number;
|
||||||
|
sshUsername: string;
|
||||||
|
sshHost: string;
|
||||||
|
resourceId: number;
|
||||||
|
siteIds: number[];
|
||||||
|
siteId: number;
|
||||||
|
keyId?: string;
|
||||||
|
validPrincipals?: string[];
|
||||||
|
validAfter?: string;
|
||||||
|
validBefore?: string;
|
||||||
|
expiresIn?: number;
|
||||||
|
authDaemonMode: "site" | "remote" | "native" | null;
|
||||||
|
};
|
||||||
@@ -6,7 +6,6 @@ import { Button } from "@/components/ui/button";
|
|||||||
import { Input } from "@/components/ui/input";
|
import { Input } from "@/components/ui/input";
|
||||||
import { Label } from "@/components/ui/label";
|
import { Label } from "@/components/ui/label";
|
||||||
import { Textarea } from "@/components/ui/textarea";
|
import { Textarea } from "@/components/ui/textarea";
|
||||||
import type { SignSshKeyResponse } from "@server/private/routers/ssh";
|
|
||||||
import { GetBrowserTargetResponse } from "@server/routers/browserGatewayTarget";
|
import { GetBrowserTargetResponse } from "@server/routers/browserGatewayTarget";
|
||||||
import {
|
import {
|
||||||
Card,
|
Card,
|
||||||
@@ -18,6 +17,7 @@ import {
|
|||||||
import Link from "next/link";
|
import Link from "next/link";
|
||||||
import { ExternalLink } from "lucide-react";
|
import { ExternalLink } from "lucide-react";
|
||||||
import { cn } from "@app/lib/cn";
|
import { cn } from "@app/lib/cn";
|
||||||
|
import type { SignSshKeyResponse } from "@server/routers/ssh/types";
|
||||||
|
|
||||||
type AuthTab = "password" | "privateKey";
|
type AuthTab = "password" | "privateKey";
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user