mcnoaa-tides/docs/astro.config.mjs
Ryan Malloy 10e9bf9185 Update docs for MCP primitives and fix Vite allowedHosts
Document tool annotations, structured logging, sampling summaries,
and the new test_client_capabilities diagnostic tool across getting
started, reference, and architecture pages. Fix Vite 6+ host blocking
when serving behind a reverse proxy.
2026-02-23 15:18:25 -07:00

63 lines
1.6 KiB
JavaScript

import { defineConfig } from "astro/config";
import starlight from "@astrojs/starlight";
const domain = process.env.DOMAIN || "localhost:4321";
const protocol = domain.startsWith("localhost") ? "http" : "https";
export default defineConfig({
site: `${protocol}://${domain}`,
telemetry: false,
devToolbar: { enabled: false },
integrations: [
starlight({
title: "mcnoaa-tides",
description:
"FastMCP server for NOAA CO-OPS tide predictions, water levels, and marine conditions.",
customCss: [
"@fontsource/inter/400.css",
"@fontsource/inter/600.css",
"@fontsource/jetbrains-mono/400.css",
"./src/styles/custom.css",
],
social: [
{
icon: "github",
label: "PyPI",
href: "https://pypi.org/project/mcnoaa-tides/",
},
],
sidebar: [
{
label: "Getting Started",
autogenerate: { directory: "getting-started" },
},
{
label: "How-To Guides",
autogenerate: { directory: "how-to" },
},
{
label: "Reference",
autogenerate: { directory: "reference" },
},
{
label: "Understanding",
autogenerate: { directory: "understanding" },
},
],
}),
],
vite: {
server: {
host: "0.0.0.0",
allowedHosts: [domain.split(":")[0]],
...(process.env.VITE_HMR_HOST && {
hmr: {
host: process.env.VITE_HMR_HOST,
protocol: "wss",
clientPort: 443,
},
}),
},
},
});