Skip to content

Hosting docs.diasantos.com

This documentation is built with MkDocs (Material theme). Output is static HTML under documentation/site/ after mkdocs build. With i18n, English is at / and Portuguese at /pt/ under the same site/ tree — nginx root stays documentation/site.

Same server as the app

Typical layout:

Path Purpose
App clone e.g. /var/www/coaching — Next.js + pm2
Docs build e.g. /var/www/coaching/documentation/site — nginx root

Build after git pull

Either run manually or add a small script / CI step:

cd /var/www/coaching/documentation
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
mkdocs build

Nginx

Use the full example (HTTP→HTTPS, TLS paths, optional asset cache) in Nginx — Coaching app and documentation and copy the template from documentation/examples/nginx/docs.diasantos.com.conf.example on the server.

Obtain certificates with certbot (or your usual ACME workflow) for docs.diasantos.com.

Optional: separate deploy

You can rsync only documentation/site/ to a static host or CDN if you prefer not to serve docs from the application server.

Admin Deploy (MkDocs)

The same Deploy page that runs git pull and next build also runs documentation/build-from-deploy.sh (pip install … --break-system-packages, then mkdocs build). See Deploy user permissions for what the coaching Unix user must be allowed to do.