Files
rdbms-playground/website/astro.config.mjs
T
claude@clouddev1 c72c624daa chore: bind website dev/preview server to IPv4 loopback (127.0.0.1)
Astro/Vite's default localhost bind resolves to IPv6 ::1 on this host,
which silently breaks `ssh -L 4321:127.0.0.1:4321` tunnels (they target
IPv4). Pin server.host to 127.0.0.1 so dev/preview is reachable over an
IPv4 loopback forward. Loopback-only — no network exposure.
2026-06-09 21:44:43 +00:00

41 lines
1.6 KiB
JavaScript

// @ts-check
import { defineConfig } from 'astro/config';
import starlight from '@astrojs/starlight';
import tailwindcss from '@tailwindcss/vite';
// https://astro.build/config
export default defineConfig({
// TODO(Phase B/SEO): set `site` to the production URL once the domain is
// known — enables the sitemap and canonical/OG URLs.
// Bind the dev/preview server to IPv4 loopback. Astro/Vite's default
// `localhost` bind resolves to IPv6 `::1` here, which breaks SSH
// `-L 4321:127.0.0.1:4321` tunnels (they target IPv4). Pinning 127.0.0.1
// keeps loopback-only access and makes tunnelling unambiguous.
server: { host: '127.0.0.1' },
integrations: [
starlight({
title: 'RDBMS Playground',
tagline: 'Learn relational databases by doing.',
// TODO(Phase B): point at the real repository once it moves to its
// public home. Omitted for now rather than linking the wrong repo.
// social: [{ icon: 'github', label: 'GitHub', href: '…' }],
customCss: ['./src/styles/global.css'],
// Pragmatic structure (ADR-0044 §7 / website/STYLE.md): Getting
// started, Guides, Reference, Concepts. Autogenerated per directory;
// in-section order is controlled by each page's `sidebar.order`
// frontmatter.
sidebar: [
{ label: 'Getting started', items: [{ autogenerate: { directory: 'getting-started' } }] },
{ label: 'Guides', items: [{ autogenerate: { directory: 'guides' } }] },
{ label: 'Reference', items: [{ autogenerate: { directory: 'reference' } }] },
{ label: 'Concepts', items: [{ autogenerate: { directory: 'concepts' } }] },
],
}),
],
vite: {
plugins: [tailwindcss()],
},
});