2025-02-15 17:39:01 +01:00
|
|
|
import fs from "fs"
|
|
|
|
import path from "path"
|
|
|
|
import matter from "gray-matter"
|
2025-02-13 17:28:49 +01:00
|
|
|
import Link from "next/link"
|
2025-02-16 14:08:50 +01:00
|
|
|
import { Play, MessageCircle, Users, Book, Database, Code } from "lucide-react"
|
2025-02-16 13:09:45 +01:00
|
|
|
import Footer2 from "@/components/footer2"
|
2025-02-13 17:28:49 +01:00
|
|
|
|
2025-02-15 17:39:01 +01:00
|
|
|
const guidesDirectory = path.join(process.cwd(), "..", "guides")
|
|
|
|
|
2025-02-13 17:28:49 +01:00
|
|
|
interface Guide {
|
|
|
|
title: string
|
|
|
|
description: string
|
|
|
|
slug: string
|
|
|
|
}
|
|
|
|
|
2025-02-15 17:39:01 +01:00
|
|
|
function getGuides(): Guide[] {
|
2025-02-16 13:44:18 +01:00
|
|
|
const guides: Guide[] = []
|
2025-02-15 17:39:01 +01:00
|
|
|
|
|
|
|
function findGuides(dir: string, basePath = "") {
|
|
|
|
fs.readdirSync(dir, { withFileTypes: true }).forEach((entry) => {
|
|
|
|
const fullPath = path.join(dir, entry.name)
|
|
|
|
const relativePath = path.join(basePath, entry.name)
|
|
|
|
|
|
|
|
if (entry.isDirectory()) {
|
|
|
|
findGuides(fullPath, relativePath)
|
|
|
|
} else if (entry.isFile() && entry.name.endsWith(".md")) {
|
|
|
|
const slug = relativePath.replace(/\.md$/, "")
|
|
|
|
|
|
|
|
const fileContents = fs.readFileSync(fullPath, "utf8")
|
|
|
|
const { data } = matter(fileContents)
|
|
|
|
|
|
|
|
guides.push({
|
|
|
|
title: data.title || slug.replace(/_/g, " "),
|
|
|
|
description: data.description || "No description available.",
|
|
|
|
slug,
|
|
|
|
})
|
|
|
|
}
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
findGuides(guidesDirectory)
|
|
|
|
return guides
|
|
|
|
}
|
2025-02-13 17:28:49 +01:00
|
|
|
|
|
|
|
export default function GuidesPage() {
|
2025-02-15 17:39:01 +01:00
|
|
|
const guides = getGuides()
|
|
|
|
|
2025-02-13 17:28:49 +01:00
|
|
|
return (
|
2025-02-16 00:55:42 +01:00
|
|
|
<div className="min-h-screen bg-gradient-to-b from-gray-900 to-gray-800 text-white pt-16 flex flex-col">
|
2025-02-16 13:44:18 +01:00
|
|
|
<div className="flex-grow container mx-auto px-4 py-16">
|
2025-02-15 23:26:41 +01:00
|
|
|
<h1 className="text-4xl font-bold mb-8">ProxMenux Guides</h1>
|
|
|
|
<p className="text-xl mb-8">Complementary guides to make the most of your Proxmox VE.</p>
|
2025-02-16 14:08:50 +01:00
|
|
|
|
|
|
|
{/* Dynamic Guides */}
|
2025-02-16 13:44:18 +01:00
|
|
|
<div className="grid md:grid-cols-2 gap-6 mb-12">
|
2025-02-15 23:26:41 +01:00
|
|
|
{guides.map((guide) => (
|
|
|
|
<Link
|
|
|
|
key={guide.slug}
|
|
|
|
href={`/guides/${guide.slug}`}
|
2025-02-15 23:41:32 +01:00
|
|
|
className="block p-6 bg-white rounded-lg shadow-md hover:shadow-lg transition-shadow"
|
2025-02-15 23:26:41 +01:00
|
|
|
>
|
2025-02-15 23:41:32 +01:00
|
|
|
<h2 className="text-2xl font-semibold mb-2 text-gray-900">{guide.title}</h2>
|
|
|
|
<p className="text-gray-600">{guide.description}</p>
|
2025-02-15 23:26:41 +01:00
|
|
|
</Link>
|
|
|
|
))}
|
|
|
|
</div>
|
2025-02-16 14:08:50 +01:00
|
|
|
|
|
|
|
{/* Additional Resources */}
|
2025-02-16 13:44:18 +01:00
|
|
|
<h2 className="text-3xl font-bold mb-6">Additional Resources</h2>
|
2025-02-16 14:08:50 +01:00
|
|
|
<div className="grid md:grid-cols-2 gap-6 mb-12">
|
2025-02-16 13:44:18 +01:00
|
|
|
<a
|
|
|
|
href="https://github.com/community-scripts/ProxmoxVE/blob/main/USER_SUBMITTED_GUIDES.md"
|
|
|
|
target="_blank"
|
|
|
|
rel="noopener noreferrer"
|
|
|
|
className="block p-6 bg-blue-600 rounded-lg shadow-md hover:bg-blue-700 transition-colors"
|
|
|
|
>
|
2025-02-16 14:08:50 +01:00
|
|
|
<div className="flex items-center gap-3 mb-2">
|
|
|
|
<Code className="h-6 w-6 text-white" />
|
2025-02-16 14:59:30 +01:00
|
|
|
<h2 className="text-2xl font-semibold text-white">Community Helper-Scripts</h2>
|
2025-02-16 14:08:50 +01:00
|
|
|
</div>
|
2025-02-16 13:44:18 +01:00
|
|
|
<p className="text-gray-200">
|
2025-02-16 14:25:47 +01:00
|
|
|
User-submitted guides and scripts for Proxmox VE from the community.
|
2025-02-16 13:44:18 +01:00
|
|
|
</p>
|
|
|
|
</a>
|
|
|
|
<a
|
|
|
|
href="https://pve.proxmox.com/pve-docs/index.html"
|
|
|
|
target="_blank"
|
|
|
|
rel="noopener noreferrer"
|
|
|
|
className="block p-6 bg-green-600 rounded-lg shadow-md hover:bg-green-700 transition-colors"
|
|
|
|
>
|
2025-02-16 14:08:50 +01:00
|
|
|
<div className="flex items-center gap-3 mb-2">
|
|
|
|
<Book className="h-6 w-6 text-white" />
|
|
|
|
<h2 className="text-2xl font-semibold text-white">Official Documentation</h2>
|
|
|
|
</div>
|
2025-02-16 14:25:47 +01:00
|
|
|
<p className="text-gray-200">
|
|
|
|
Comprehensive Proxmox VE documentation and administration guide available.
|
|
|
|
</p>
|
2025-02-16 14:08:50 +01:00
|
|
|
</a>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
{/* PBS Documentation */}
|
|
|
|
<h2 className="text-3xl font-bold mb-6">Backup Server Documentation</h2>
|
|
|
|
<div className="mb-12">
|
|
|
|
<a
|
|
|
|
href="https://pbs.proxmox.com/docs/index.html"
|
|
|
|
target="_blank"
|
|
|
|
rel="noopener noreferrer"
|
|
|
|
className="block p-6 bg-yellow-600 rounded-lg shadow-md hover:bg-yellow-700 transition-colors"
|
|
|
|
>
|
|
|
|
<div className="flex items-center gap-3 mb-2">
|
|
|
|
<Database className="h-6 w-6 text-white" />
|
|
|
|
<h2 className="text-2xl font-semibold text-white">Backup Server Docs</h2>
|
|
|
|
</div>
|
2025-02-16 13:44:18 +01:00
|
|
|
<p className="text-gray-200">
|
2025-02-16 14:25:47 +01:00
|
|
|
Information about Proxmox Backup Server, a powerful backup solution for Proxmox VE.
|
2025-02-16 13:44:18 +01:00
|
|
|
</p>
|
|
|
|
</a>
|
|
|
|
</div>
|
2025-02-16 14:08:50 +01:00
|
|
|
|
|
|
|
{/* Video Tutorials */}
|
|
|
|
<h2 className="text-3xl font-bold mb-6">Video Tutorials</h2>
|
|
|
|
<div className="mb-12">
|
|
|
|
<a
|
|
|
|
href="https://www.proxmox.com/en/services/training-courses/videos?utm_source"
|
|
|
|
target="_blank"
|
|
|
|
rel="noopener noreferrer"
|
|
|
|
className="block p-6 bg-red-600 rounded-lg shadow-md hover:bg-red-700 transition-colors"
|
|
|
|
>
|
|
|
|
<div className="flex items-center gap-3 mb-2">
|
|
|
|
<Play className="h-6 w-6 text-white" />
|
|
|
|
<h2 className="text-2xl font-semibold text-white">Official Video Training</h2>
|
|
|
|
</div>
|
|
|
|
<p className="text-gray-200">
|
2025-02-16 14:25:47 +01:00
|
|
|
Access official Proxmox video tutorials and training courses for skill development.
|
2025-02-16 14:08:50 +01:00
|
|
|
</p>
|
|
|
|
</a>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
{/* Community Discussion */}
|
|
|
|
<h2 className="text-3xl font-bold mb-6">Community Discussion</h2>
|
|
|
|
<div className="grid md:grid-cols-2 gap-6">
|
|
|
|
<a
|
|
|
|
href="https://forum.proxmox.com/"
|
|
|
|
target="_blank"
|
|
|
|
rel="noopener noreferrer"
|
|
|
|
className="block p-6 bg-purple-600 rounded-lg shadow-md hover:bg-purple-700 transition-colors"
|
|
|
|
>
|
|
|
|
<div className="flex items-center gap-3 mb-2">
|
|
|
|
<MessageCircle className="h-6 w-6 text-white" />
|
|
|
|
<h2 className="text-2xl font-semibold text-white">Proxmox Forum</h2>
|
|
|
|
</div>
|
2025-02-16 14:25:47 +01:00
|
|
|
<p className="text-gray-200">Access the official Proxmox forum for questions, troubleshooting, and shared experiences.</p>
|
2025-02-16 14:08:50 +01:00
|
|
|
</a>
|
|
|
|
<a
|
|
|
|
href="https://www.reddit.com/r/Proxmox/"
|
|
|
|
target="_blank"
|
|
|
|
rel="noopener noreferrer"
|
|
|
|
className="block p-6 bg-orange-600 rounded-lg shadow-md hover:bg-orange-700 transition-colors"
|
|
|
|
>
|
|
|
|
<div className="flex items-center gap-3 mb-2">
|
|
|
|
<Users className="h-6 w-6 text-white" />
|
|
|
|
<h2 className="text-2xl font-semibold text-white">Proxmox Reddit</h2>
|
|
|
|
</div>
|
2025-02-16 14:25:47 +01:00
|
|
|
<p className="text-gray-200">Access the Proxmox community on Reddit for discussions, tips, and technical support.</p>
|
2025-02-16 14:08:50 +01:00
|
|
|
</a>
|
|
|
|
</div>
|
2025-02-13 17:28:49 +01:00
|
|
|
</div>
|
2025-02-16 12:56:04 +01:00
|
|
|
<Footer2 />
|
2025-02-13 17:28:49 +01:00
|
|
|
</div>
|
|
|
|
)
|
|
|
|
}
|