Tag: docker

  • Building a Git-Versioned Digital Garden with WordPress, Docker & Tailscale

    Building a Git-Versioned Digital Garden with WordPress, Docker & Tailscale

    A fast, Git-versioned, Markdown-first personal knowledge base and digital garden powered by WordPress, Docker, and Tailscale.


    Obsidian & Markdown Compatibility

    Write notes locally in your favorite editor (like Obsidian). All <a href="/wikilinks/" class="internal-link" data-slug="wikilinks">wikilinks</a>, callouts, code blocks, and math formulas automatically compile into this live site.


    🏗️ System Architecture (Mermaid.js Flowchart)

    Here is how local Markdown files automatically flow into this live site:

    graph TD
        A[📝 Local Markdown / Obsidian] -->|git commit & push| B[🐙 GitHub Repository]
        A -->|uv run scripts/sync.py| C[⚡ WP-CLI Engine]
        C -->|Auto-provision & Upsert| D[(🐬 MariaDB 11.4)]
        D -->|Render PHP 8.3 & HTML| E[🔒 Caddy Reverse Proxy]
        E -->|HTTPS / Tailscale| F[🌐 Reader / Web Browser]
    

    📐 Mathematical Equations (KaTeX LaTeX)

    Supports both inline equations like $E = mc^2$ and Euler’s formula $e^{i\pi} + 1 = 0$, as well as block LaTeX equations:

    $$\sum_{k=1}^{n} k^2 = \frac{n(n+1)(2n+1)}{6}$$


    🌿 Digital Garden Interconnections

    Explore connected notes and thoughts across the garden:
    – Read the Getting Started with Markdown guide.
    – Check out the About This Site page.


    Explore The Garden

    Use the 🗂️ Filetree Explorer on the left to browse all pages and articles, press Ctrl + K to search instantly, or explore the interactive force graph below!

  • Getting Started with Markdown in WordPress

    Getting Started with Markdown in WordPress

    Welcome to your Git-versioned, Markdown-first WordPress site with full Digital Garden features!


    Obsidian Compatibility

    You can write notes directly in Obsidian and sync them here. All wikilinks like about and Home Page work automatically.

    Architecture Flow

    Here is how local Markdown files flow into your live WordPress site:

    graph TD
        A[Obsidian / Local Markdown] -->|git commit & push| B[GitHub Repo]
        A -->|uv run scripts/sync.py| C[WP-CLI Container]
        C -->|Upsert Content & Graph| D[WordPress MariaDB]
        D -->|Serve Rendered Notes| E[Caddy Reverse Proxy]
        E -->|HTTPS| F[Readers / Browser]
    

    Why This Setup?

    This workflow gives you the best of both worlds:
    1. Developer Experience: Write posts in your favorite local editor using standard Markdown.
    2. Git Version Control: Every edit, draft, and revision is tracked in GitHub.
    3. Interactive Graph & Previews: Seamless navigation across connected thoughts.

    Math Equation Example

    KaTeX dynamically renders inline math like $E = mc^2$ and block equations:

    $$\sum_{k=1}^{n} k = \frac{n(n+1)}{2}$$

    Obsidian Callout Box Examples


    Information Box

    Standard informational callout with clean accent styling.


    Important Warning

    Be careful when editing database tables directly; always use wp db export or sync.py!


    Key Requirement

    Run uv run scripts/sync.py to synchronize any updated markdown files into WordPress.

    Code Example

    Here is a quick Python example demonstrating how clean code blocks render:

    def publish_post(title: str, content: str) -> bool:
        print(f"Publishing post: {title}")
        return True
    

    Backlinks and Interconnections

    This note connects back to the Home Page and the About Site page.

🌐 Global Interactive Graph View
Fullscreen image