main-ops #1

Merged
mik-tf merged 7 commits from main-ops into main 2025-09-30 17:07:30 +00:00
Showing only changes of commit 19552a2b55 - Show all commits

View File

@@ -1,8 +1,8 @@
# Deployment Guide for Mycelium Society Docs
This guide provides a deployment for serving the Mycelium Society documentation at `docs.mycelium.tf` by proxying to the existing content at `https://docs.ourworld.tf/mycelium_society/docs/`.
This guide provides a deployment for serving the Mycelium Society documentation at `docs.mycelium.tf`.
This allows users to access the docs via `docs.mycelium.tf` while the content is hosted elsewhere.
We build the docs website with hero docusaurus then we serve directly from files.
## Prerequisites
@@ -12,7 +12,7 @@ This allows users to access the docs via `docs.mycelium.tf` while the content is
## Step 1: Configure Caddy
Update your Caddyfile to include the docs proxy:
Update your Caddyfile to include the docs serving:
```bash
# Edit the Caddyfile (adjust path to your Caddyfile location)
@@ -29,13 +29,10 @@ Create `mycelium_docs.caddy`:
```
docs.mycelium.tf {
rewrite * /mycelium_society/docs{uri}
reverse_proxy https://docs.ourworld.tf {
header_up Host docs.ourworld.tf
header_up X-Forwarded-Proto https
header_up X-Real-IP {remote}
header_up X-Forwarded-Host {host}
}
root * /root/hero/www/info/mycelium_society
encode gzip
try_files {path} {path}/ /index.html
file_server
}
```
@@ -45,6 +42,16 @@ docs.mycelium.tf {
zinit restart caddy
```
## Building and Publishing Docs
Users can build and publish the docs using:
```bash
hero docusaurus -path ~/code/git.ourworld.tf/tfgrid/docs_tfgrid4/ebooks/mycelium_society -d
```
This builds the Docusaurus site and deploys it to `/root/hero/www/info/mycelium_society`.
## Monitoring
- Check Caddy status: `zinit list`
@@ -54,5 +61,5 @@ zinit restart caddy
## Notes
- Ensure DNS for `docs.mycelium.tf` points to your server.
- The content is served from `https://docs.ourworld.tf/mycelium_society/docs/`, but users see `docs.mycelium.tf`.
- No additional build or cloning required; it's a reverse proxy setup.
- The content is served directly from static files at `/root/hero/www/info/mycelium_society`.
- Build and deploy using the hero command above.