import type { Metadata } from "next" import { getTranslations, getMessages, setRequestLocale } from "next-intl/server" import { DocHeader } from "@/components/ui/doc-header" import { Callout } from "@/components/ui/callout" import Image from "next/image" import CopyableCode from "@/components/CopyableCode" import Footer from "@/components/footer" export async function generateMetadata({ params, }: { params: Promise<{ locale: string }> }): Promise { const { locale } = await params const t = await getTranslations({ locale, namespace: "guides.lxcSamba.meta" }) return { title: t("title"), description: t("description"), alternates: { canonical: "https://proxmenux.com/docs/guides/lxc-samba" }, openGraph: { title: t("ogTitle"), description: t("ogDescription"), type: "article", url: "https://proxmenux.com/docs/guides/lxc-samba", }, } } export default async function LxcSambaGuide({ params, }: { params: Promise<{ locale: string }> }) { const { locale } = await params setRequestLocale(locale) const t = await getTranslations({ locale, namespace: "guides.lxcSamba" }) const messages = (await getMessages({ locale })) as unknown as { guides: { lxcSamba: { recommended: { items: string[] } intro: { steps: string[]; useCases: string[] } troubleshoot: { items: string[] } } } } const recommendedItems = messages.guides.lxcSamba.recommended.items const introSteps = messages.guides.lxcSamba.intro.steps const useCases = messages.guides.lxcSamba.intro.useCases const troubleItems = messages.guides.lxcSamba.troubleshoot.items const code = (chunks: React.ReactNode) => {chunks} const strong = (chunks: React.ReactNode) => {chunks} return (

{t("recommended.calloutIntro")}

    {recommendedItems.map((_, idx) => (
  • {t.rich(`recommended.items.${idx}`, { strong, code })}
  • ))}

{t("recommended.calloutOutro")}

{t("intro.body")}

{t("intro.stepsTitle")}

    {introSteps.map((_, idx) => (
  1. {t(`intro.steps.${idx}`)}
  2. ))}

{t("intro.useCasesTitle")}

    {useCases.map((_, idx) => (
  • {t(`intro.useCases.${idx}`)}
  • ))}
{t.rich("intro.privilegedCalloutBody", { strong, code })}

{t("attach.heading")}

{t("attach.identifyHeading")}

{t.rich("attach.identifyBody", { strong })}

{t("attach.beforeLabel")}

{t("attach.imageBeforeAlt")}

{t("attach.afterLabel")}

{t("attach.imageAfterAlt")}

{t.rich("attach.lsblkBody", { code })}

{t.rich("attach.stableCalloutBody", { code })}

{t.rich("attach.stableCalloutAfter", { code })}

{t("attach.formatHeading")}

{t.rich("attach.formatBody", { strong })}

{t.rich("attach.formatAfter", { code })}

{t("attach.mkdirHeading")}

{t("attach.mkdirBody")}

{t("attach.wireHeading")}

{t.rich("attach.wireBody", { strong, code })}

{t("attach.wireAddLine")}

{t.rich("attach.wireShortForm", { code })}

{t.rich("attach.wireBackupNote", { code })}

{t("attach.restartHeading")}

{t("attach.restartBody")}

{t("attach.permsBody")}

{t.rich("attach.permsNote", { code })}

{t("samba.heading")}

{t("samba.installHeading")}

{t("samba.confirmBody")}

{t("samba.userHeading")}

{t.rich("samba.userBody", { code })}

{t("samba.passwordBody")}

{t("samba.aclHeading")}

{t.rich("samba.aclBody", { code })}

{t("configure.heading")}

{t("configure.editHeading")}

{t("configure.appendBody")}

{t.rich("configure.validUsersNote", { code })}

{t("configure.reloadHeading")}

{t("verify.heading")}

{t.rich("verify.body", { code })}

{t("verify.image1Alt")} {t("verify.image2Alt")}

{t("verify.usageBody")}

{t("verify.image3Alt")}

{t("troubleshoot.heading")}

    {troubleItems.map((_, idx) => (
  • {t.rich(`troubleshoot.items.${idx}`, { code, strong })}
  • ))}
) }