feat: add React UI for rpm.lair.cafe
- Vite + React + SWC + TypeScript SPA with react-router and react-bootstrap - Dark/light/system theme with Bootstrap 5.3 data-bs-theme - Home page with repo setup instructions and copyable code blocks - Package list and detail pages driven by packages.json - Python script to generate packages.json from repodata XML - Nginx config updated for SPA fallback, asset caching, removed autoindex - New deploy-ui workflow triggered on ui/ or nginx config changes, requires runners with nvm label - packages.json generation added to publish job after createrepo_c - Runner setup docs for nvm and sequoia-sq added to readme Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
49
ui/src/pages/Home.tsx
Normal file
49
ui/src/pages/Home.tsx
Normal file
@@ -0,0 +1,49 @@
|
||||
import { Card, Col, Row } from "react-bootstrap";
|
||||
import { CodeBlock } from "../components/CodeBlock.tsx";
|
||||
|
||||
const GPG_KEY_URL = "https://rpm.lair.cafe/8b2023ce.gpg";
|
||||
|
||||
const REPO_FILE = `[lair-cafe]
|
||||
name=lair.cafe RPM Repository
|
||||
baseurl=https://rpm.lair.cafe/fedora/$releasever/$basearch/
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=${GPG_KEY_URL}`;
|
||||
|
||||
export function Home() {
|
||||
return (
|
||||
<>
|
||||
<h1 className="mb-3">rpm.lair.cafe</h1>
|
||||
<p className="lead mb-4">
|
||||
Self-hosted RPM repository for Fedora, currently hosting CUDA-accelerated
|
||||
builds of{" "}
|
||||
<a href="https://github.com/EricLBuehler/mistral.rs">mistral.rs</a>.
|
||||
</p>
|
||||
|
||||
<Row className="g-4">
|
||||
<Col lg={12}>
|
||||
<Card>
|
||||
<Card.Body>
|
||||
<Card.Title>Quick start</Card.Title>
|
||||
|
||||
<h6 className="mt-4">1. Import the signing key</h6>
|
||||
<CodeBlock language="bash">
|
||||
{`sudo rpm --import ${GPG_KEY_URL}`}
|
||||
</CodeBlock>
|
||||
|
||||
<h6 className="mt-4">2. Add the repository</h6>
|
||||
<CodeBlock language="bash">
|
||||
{`sudo dnf config-manager addrepo --from-repofile=/dev/stdin <<'EOF'\n${REPO_FILE}\nEOF`}
|
||||
</CodeBlock>
|
||||
|
||||
<h6 className="mt-4">3. Install a package</h6>
|
||||
<CodeBlock language="bash">
|
||||
{`sudo dnf install mistralrs-server-cuda13`}
|
||||
</CodeBlock>
|
||||
</Card.Body>
|
||||
</Card>
|
||||
</Col>
|
||||
</Row>
|
||||
</>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user