Skip to content

Docs: nginx static assets (alias) for AOT deploy dist #696

@PurHur

Description

@PurHur

Problem

docs/deploy-web-aot.md (#635) documents phpc deploy layout and CGI for bin/app, but production sites also serve assets/ (CSS) and optionally public/ static files. MiniWebApp relies on /assets/style.css (#594 closed for VM serve; AOT deploy still needs nginx rules).

Contributors are unsure whether static files are served by the native binary, phpc serve, or nginx alias/try_files.

Goal

Extend deployment docs (umbrella #445 or docs/deploy-web-aot.md) with copy-paste nginx snippets:

  1. PHPC_DEPLOY_ROOT + alias for assets/ and public/
  2. Front controller: only *.php → CGI/FastCGI to bin/app
  3. Local smoke: curl CSS from deployed dist before nginx (file exists)

Scope

Acceptance criteria

  • Doc section committed; linked from examples/003-MiniWebApp/README.md deploy section
  • Reviewer can deploy 002-StaticWeb or 003-MiniWebApp dist and serve CSS via nginx config without reading source

Verification (local only)

./phpc deploy examples/002-StaticWeb -o /tmp/static-dist
test -f /tmp/static-dist/README.deploy
# Manual: nginx -t with snippet pasted from doc (not automated)

No GitHub Actions.

Dependencies

Links

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:toolingTooling / CI / docsarea:webWeb / CGI / superglobalsenhancementNew feature or requestphase-3:aotPhase 3 – AOT deployment

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions