import { Card, CardContent, CardDescription, CardHeader, CardTitle, } from "@/components/ui/card"; import { api } from "@/utils/api"; import { Server } from "lucide-react"; import { AddRegistry } from "./add-docker-registry"; import { AddSelfHostedRegistry } from "./add-self-docker-registry"; import { DeleteRegistry } from "./delete-registry"; import { UpdateDockerRegistry } from "./update-docker-registry"; export const ShowRegistry = () => { const { data } = api.registry.all.useQuery(); const haveSelfHostedRegistry = data?.some( (registry) => registry.registryType === "selfHosted", ); return (
Registry Add registry to your application.
{data && data?.length > 0 && ( <> {!haveSelfHostedRegistry && } )}
{data?.length === 0 ? (
To create a cluster is required to set a registry.
) : (
{data?.map((registry, index) => (
{index + 1}. {registry.registryName}
))}
)}
); };