From 7b95d009516a5229e93accdffd4748a77bdaca22 Mon Sep 17 00:00:00 2001 From: Derek Mackley Date: Sat, 21 Nov 2026 19:20:59 -0600 Subject: [PATCH 1/8] link the docs, storybook and blog from every page, start the blog, and show flux health in the telemetry band --- config/vite/prod/clusterStatus.js | 4 + config/vite/server.js | 7 ++ docs/_architecture/build-deployment.md | 2 +- docs/_config.yml | 8 ++ docs/_guides/customization-guide.md | 2 +- docs/_layouts/default.html | 2 +- docs/_layouts/post.html | 24 ++++++ docs/_posts/.gitkeep | 0 docs/_sass/layout.scss | 43 +++++++++- docs/blog/index.html | 24 ++++++ src/components/layout/Footer/Footer.tsx | 7 ++ .../layout/Navigation/Navigation.tsx | 22 +++-- .../molecules/SiteLinks/SiteLinks.css | 66 +++++++++++++++ .../molecules/SiteLinks/SiteLinks.stories.tsx | 69 ++++++++++++++++ .../molecules/SiteLinks/SiteLinks.test.tsx | 34 ++++++++ .../molecules/SiteLinks/SiteLinks.tsx | 42 ++++++++++ src/components/molecules/SiteLinks/index.ts | 2 + .../VersionChips/VersionChips.stories.tsx | 16 ++++ .../molecules/VersionChips/VersionChips.tsx | 6 +- .../ClusterTelemetry/ClusterTelemetry.css | 30 +++++++ .../ClusterTelemetry.stories.tsx | 56 ++++++++++++- .../ClusterTelemetry/ClusterTelemetry.tsx | 15 +++- .../organisms/Greetings/Greetings.tsx | 8 ++ .../organisms/Greetings/commands.test.ts | 57 +++++++++++++ .../organisms/Greetings/commands.ts | 80 +++++++++++++++++-- src/portfolio.ts | 10 +++ src/types/portfolio.d.ts | 11 +++ src/utils/__tests__/clusterTelemetry.test.ts | 42 +++++++++- src/utils/clusterTelemetry.ts | 41 +++++++++- 29 files changed, 706 insertions(+), 24 deletions(-) create mode 100644 docs/_layouts/post.html create mode 100644 docs/_posts/.gitkeep create mode 100644 docs/blog/index.html create mode 100644 src/components/molecules/SiteLinks/SiteLinks.css create mode 100644 src/components/molecules/SiteLinks/SiteLinks.stories.tsx create mode 100644 src/components/molecules/SiteLinks/SiteLinks.test.tsx create mode 100644 src/components/molecules/SiteLinks/SiteLinks.tsx create mode 100644 src/components/molecules/SiteLinks/index.ts diff --git a/config/vite/prod/clusterStatus.js b/config/vite/prod/clusterStatus.js index 7053390d..c1bbc6ae 100644 --- a/config/vite/prod/clusterStatus.js +++ b/config/vite/prod/clusterStatus.js @@ -18,6 +18,10 @@ export const CLUSTER_BADGE_IDS = [ 'talos_version', 'kubernetes_version', 'flux_version', + 'flux_kustomization_count', + 'flux_helmrelease_count', + 'flux_waiting_count', + 'flux_failing_count', ]; const DEFAULT_KROMGO_URL = 'https://kromgo.chelonianlabs.com'; diff --git a/config/vite/server.js b/config/vite/server.js index 9dec1dad..911946ab 100644 --- a/config/vite/server.js +++ b/config/vite/server.js @@ -172,6 +172,13 @@ export function createBaseServer(config = {}) { } }); + // The blog is built inside the Jekyll docs (/docs/blog/). /blog is the short + // address people share, so send it there. 302 so the blog can move later. + // req.url is relative to the mount, so the target always stays under /docs. + app.use('/blog', (req, res) => { + res.redirect(302, `/docs/blog${req.url}`); + }); + // Path-based routing for docs and storybook MUST come before general static serving // Serve documentation at /docs route app.use('/docs', express.static(docsPath, { diff --git a/docs/_architecture/build-deployment.md b/docs/_architecture/build-deployment.md index 1e097560..01b4613c 100644 --- a/docs/_architecture/build-deployment.md +++ b/docs/_architecture/build-deployment.md @@ -248,7 +248,7 @@ jobs: - name: Run Snyk security scan uses: snyk/actions/node@master env: - SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }} + SNYK_TOKEN: ${% raw %}{{ secrets.SNYK_TOKEN }}{% endraw %} build: needs: [validate, security] diff --git a/docs/_config.yml b/docs/_config.yml index 4366588e..a7b62a16 100644 --- a/docs/_config.yml +++ b/docs/_config.yml @@ -36,6 +36,13 @@ nav_sections: path: "/guides/" - title: "Hooks" path: "/hooks/" + - title: "Blog" + path: "/blog/" + # `url` entries leave the docs build and are used as-is + - title: "Components" + url: "/storybook/" + - title: "← Main site" + url: "/" # Kramdown settings kramdown: @@ -78,6 +85,7 @@ defaults: type: "posts" values: layout: "post" + permalink: /blog/:year/:month/:title/ author: "Derek Mackley" - scope: path: "" diff --git a/docs/_guides/customization-guide.md b/docs/_guides/customization-guide.md index 2793bad0..6f816b3c 100644 --- a/docs/_guides/customization-guide.md +++ b/docs/_guides/customization-guide.md @@ -515,7 +515,7 @@ The portfolio includes support for dark mode. To customize dark mode colors: function CustomButton() { return ( - ); diff --git a/docs/_layouts/default.html b/docs/_layouts/default.html index a184add1..849023ea 100644 --- a/docs/_layouts/default.html +++ b/docs/_layouts/default.html @@ -24,7 +24,7 @@