Commit Graph
4 Commits
Author SHA1 Message Date
Artur MoreiraandPaperclip a77c293d0e feat(wordpress): nginx + PHP-FPM stacks; retire Apache images (BIT-578)
- Use wordpress:6-php8.3-fpm with nginx:alpine sidecars; keep host ports 8080/8081
- Add shared wp_html / wp_andebol_html volumes so nginx can serve the same docroot as FPM
- Nginx: try_files permalinks, proxy headers, HTTP_AUTHORIZATION for App Passwords
- Update deploy scripts to force-recreate nginx with wordpress when public URL is fixed
- Refresh README and deployment docs

Co-Authored-By: Paperclip <[email protected]>
Made-with: Cursor
2026-03-28 01:15:51 +00:00
Artur Moreira e15e88ef6c fix(nginx): default_server for all NPM hostnames + WP port map
Use default_server and server_name _ so domains like andebol.net reach Astro
instead of the Debian nginx welcome page. Install map Host→WordPress port
(8080 default, andebol.net→8081). deploy.sh and webhook-deploy install
conf.d snippet and remove sites-enabled/default.

docs/deployment.md: document multi-domain NPM workflow.

Refs: BIT-345
2026-03-25 12:34:18 +00:00
Artur Moreira 5e14e2df47 fix(deploy): auto-set WordPress public URL and sync wp_options on LXC
Add wordpress-ensure-public-url.sh (exit 2 when .env updated) and
wordpress-sync-options-url.sh to align siteurl/home with HTTPS. Wire
into deploy.sh and webhook-deploy.sh for /opt/news-platform only so
the board does not need manual .env or SQL for BIT-470/BIT-471.

Made-with: Cursor
2026-03-24 19:02:10 +00:00
Artur MoreiraandPaperclip 0e3a1afb3b feat: deploy pipeline — systemd units, Nginx, deploy scripts (BIT-352)
deploy/systemd/:
  - news-frontend.service (Astro SSR :4321)
  - news-bridge.service (Fastify :3200)
  - news-wordpress.service (Docker Compose wrapper)
  - frontend.env.example + bridge.env.example

deploy/nginx/:
  - newsproject.bitreport.pt.conf (reverse proxy → :4321, /api/ → :3200)
  - Nginx config validated OK on CT 222

deploy/scripts/:
  - deploy.sh — full from-scratch deploy (clone, build, install, start)
  - webhook-deploy.sh — incremental deploy on git push (cron-friendly)

Tested on CT 222 (10.10.50.140):
  - nginx -t → OK
  - systemd units installed (news-frontend/bridge/wordpress)
  - news-wordpress enabled; frontend/bridge pending Astro build

Remaining manual steps:
  - DHCP reservation for 10.10.50.140
  - NPM proxy host: newsproject.bitreport.pt → http://10.10.50.140
  - Run deploy.sh after bridge.env and frontend.env are configured

Co-Authored-By: Paperclip <[email protected]>
Made-with: Cursor
2026-03-23 15:48:43 +00:00