From db6aaf433d43d5b09078b2f27665007453b3c928 Mon Sep 17 00:00:00 2001 From: adrien Date: Sat, 25 Apr 2026 23:29:06 +0200 Subject: [PATCH] Added mkdocs --- .gitea/workflows/deploy.yml | 29 ++++++++++++++++++++++ docs/index.md | 26 ++++++++++++++++++++ mkdocs.yml | 48 +++++++++++++++++++++++++++++++++++++ 3 files changed, 103 insertions(+) create mode 100644 .gitea/workflows/deploy.yml create mode 100644 docs/index.md create mode 100644 mkdocs.yml diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml new file mode 100644 index 0000000..150c668 --- /dev/null +++ b/.gitea/workflows/deploy.yml @@ -0,0 +1,29 @@ +name: Deploy MkDocs to Garage +on: + push: + branches: + - main # Adjust to your branch name + +jobs: + build-and-deploy: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Build MkDocs Material + # We use the official image to build the site into the 'site' folder + run: | + docker run --rm -v "${{ github.workspace }}:/docs" \ + squidfunk/mkdocs-material build + + - name: Sync to Garage S3 + uses: https://github.com/jakejarvis/s3-sync-action@master + with: + args: --endpoint-url https://s3.garage.bouvais.lu --acl public-read --delete + env: + AWS_S3_BUCKET: 'zig-dimal.bouvais.lu' + AWS_ACCESS_KEY_ID: ${{ secrets.GARAGE_ACCESS_KEY }} + AWS_SECRET_ACCESS_KEY: ${{ secrets.GARAGE_SECRET_KEY }} + AWS_REGION: 'garage' + SOURCE_DIR: 'site' # MkDocs defaults to 'site' folder for output diff --git a/docs/index.md b/docs/index.md new file mode 100644 index 0000000..3aeb3d3 --- /dev/null +++ b/docs/index.md @@ -0,0 +1,26 @@ +# Welcome to My Project + +This is a static site hosted via **Gitea Actions** and **Garage S3 Storage**. + +!!! info "Status" + The deployment pipeline is currently **Active**. + Updates to the `main` branch are pushed automatically. + +## Quick Start + +To replicate this setup, you need: +1. **Traefik** as the reverse proxy. +2. **Garage** for S3-compatible web hosting. +3. **Gitea** for version control and CI. + +### Deployment Details +| Component | Technology | +| :--- | :--- | +| **Engine** | MkDocs Material | +| **Hosting** | Garage S3 | +| **Routing** | Traefik | + +--- + +## Contact +If you have questions, reach out via the Gitea instance. diff --git a/mkdocs.yml b/mkdocs.yml new file mode 100644 index 0000000..48fc8ad --- /dev/null +++ b/mkdocs.yml @@ -0,0 +1,48 @@ +site_name: Bouvais Docs +site_url: https://zig-dimal.bouvais.lu +site_description: A minimal technical documentation site. +site_author: Adrien Bouvais + +theme: + name: material + language: en + # Color palette with auto light/dark mode + palette: + - media: "(prefers-color-scheme: light)" + scheme: default + primary: indigo + accent: indigo + toggle: + icon: material/brightness-7 + name: Switch to dark mode + - media: "(prefers-color-scheme: dark)" + scheme: slate + primary: indigo + accent: indigo + toggle: + icon: material/brightness-4 + name: Switch to light mode + + features: + - navigation.sections + - navigation.top + - content.code.copy + - content.code.annotate + +# Minimal plugins +plugins: + - search + +# Your single page +nav: + - Home: index.md + +# Extensions to make your markdown look better +markdown_extensions: + - admonition + - pymdownx.details + - pymdownx.superfences + - pymdownx.highlight: + anchor_linenums: true + - pymdownx.inlinehilite + - attr_list