Skip to content

Latest commit

 

History

History
118 lines (80 loc) · 4.12 KB

File metadata and controls

118 lines (80 loc) · 4.12 KB

Kopexa Docs

PR Checks Main Checks License: MIT

Public documentation for Kopexa’s ISMS/GRC platform (ISO 27001, GDPR, DORA, NIS2, …). It includes end‑user guides and developer docs. Built with Next.js App Router, Fumadocs, TypeScript, and Tailwind CSS.

Quick start

Development server:

pnpm install
pnpm dev

Open http://localhost:3000 to view the site.

Configuration

  • Environment variables (common):
    • NODE_ENV — production/development
    • NEXT_TELEMETRY_DISABLED — set to 1 to disable Next telemetry
    • PORT — defaults to 3000 (container)
    • HOSTNAME — defaults to 0.0.0.0 (container)
    • Optional: NEXT_PUBLIC_SITE_URL for absolute links if needed
  • i18n: see src/lib/i18n.ts to add or adjust supported languages.
  • Content source and schemas: source.config.ts (Fumadocs MDX collections and frontmatter/meta schemas).

Project structure

  • src/app/(home): Landing and marketing pages
  • src/app/[lang]/docs: Documentation routes (Fumadocs)
  • content/: MD/MDX content for the docs
  • src/components/: UI components for the docs site
  • src/lib/: Shared utilities (i18n, layout, sources)

Key files:

  • source.config.ts: Fumadocs source + schema
  • src/lib/layout.shared.tsx: Shared layout options (links, nav)
  • src/app/api/search/route.ts: Search API
  • src/app/api/healthz/route.ts: Liveness probe (Kubernetes)
  • src/app/api/readyz/route.ts: Readiness probe (Kubernetes)

Docker

This repo includes a production-ready Dockerfile using Next.js standalone output.

Build locally:

docker build -t ghcr.io/<owner>/<repo>:dev .

Run the container:

docker run --rm -p 3000:3000 ghcr.io/<owner>/<repo>:dev

The container listens on port 3000 and binds to 0.0.0.0. Entry command runs node server.js produced by Next.js standalone build.

Deployment

docs.kopexa.com is deployed automatically on every push to main by Coolify (self-hosted on the Kopexa OVH cluster). Coolify watches this repository, builds the Dockerfile, and rolls the container out. A merge to main is sufficient to go live; no GitHub release is required.

The Docker image:

  • Standalone Next.js build, EXPOSE 3000, listens on 0.0.0.0
  • Health endpoints (used by Coolify):
    • Liveness: GET /api/healthz
    • Readiness: GET /api/readyz

CI/CD

GitHub Actions in this repo are advisory only. They give developers fast feedback but do not gate or trigger the production deploy (Coolify does that, see above).

  • PR checks: .github/workflows/pr.yml runs lint, typecheck and build (.github/workflows/lint.yml, .github/workflows/build.yml)
  • Main checks: .github/workflows/main.yml runs the same lint and build jobs on every push to main so failures are visible immediately

Contributing

We welcome fixes and improvements to keep docs accurate and helpful. For larger changes, please open an issue or draft PR first.

  • Branch naming: feat/..., fix/..., chore/..., docs/...
  • Commits: Conventional Commits (e.g., docs: update spaces guide)
  • Lint/Format: pnpm lint and pnpm format (Biome)
  • Typecheck: pnpm typecheck (TypeScript)
  • Local tasks: see Taskfile.dist.yml (task dev, task lint, task docker:build IMAGE_TAG=...)

Credits (FOSS)

Kopexa Docs are powered by:

Thanks to the FOSS community for making this stack possible.

License

Roadmap (short)

  • More multi-language content
  • Additional framework guides (TISAX, ISO 27017, …)
  • Search improvements and content structure refinements