elviraandClaude Opus 5.5 6d88d53882 Infra: Caddy instead of nginx (plain swap, TLS stays in front)
Caddy 2.11.7 built with xcaddy, with caddy-ratelimit pinned to commit
5625512f (for M3/F7 later; its only tag is years old). Prod bakes
public/ and the config into the image (target caddy); dev uses the
caddy-base stage with docker/caddy and public/ bind-mounted.

It's a 1:1 swap for the host's TLS proxy: plain HTTP on
127.0.0.1:${APP_PORT:-8090}, auto_https off, and
trusted_proxies private_ranges so the proxy's X-Forwarded-* headers
still reach Laravel (checked: https + forwarded host in redirects, as
before). Narrow that range once it's known where TLS ends.

Carried over from nginx:
- php_fastcgi to app:9000, 300s read timeout, try_files to index.php
- /build, /static, /packages and /storage (from the storage volume)
  with Cache-Control "public, max-age=31536000, immutable"
- /sitemap.xml from storage/app, max-age=3600, application/xml
- X-Frame-Options SAMEORIGIN + X-Content-Type-Options nosniff
- 100 MiB upload limit (413 above, as before)
- dotfiles denied except /.well-known/
- /stoic/ proxied to stoic:2727, prefix stripped, cookie paths
  rewritten to /stoic/
- access log to stdout, favicon/robots not logged

Changed on purpose:
- FastCGI page cache dropped (and X-Cache-Status with it). The static
  page cache comes later (P2). It also replayed the first visitor's
  Set-Cookie (session + XSRF) to other guests, since it ignored
  Set-Cookie and keyed on URL only.
- New: zstd/gzip compression for text responses (nginx had none).
- Security headers now on every response; prod nginx dropped them on
  PHP responses and on 4xx/5xx.
- A missing file under the static paths is a plain 404 instead of
  Laravel's page with a 404 status.
- No Via or CGI Status header; one Content-Type on the sitemap (nginx
  sent two).
- Dropped as unneeded: open_file_cache, fastcgi buffers/keepalive,
  `charset utf-8` (Caddy's MIME types carry it where it matters).

Stoic's dev config called the app at http://nginx/validate; it's now
http://caddy/validate. bootstrap/app.php and .env.example comments
updated. docker/nginx/ is removed.

Not in this repo, not changed: boboko-test and the boboko starter
still use nginx.

Deploy note: the service is renamed nginx -> caddy; Envoy's
`up -d --remove-orphans` removes the old nginx container. Expect a few
seconds without a listener on 8090 while it swaps.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 01:01:13 +02:00
2026-07-03 13:46:54 +00:00
2026-10-27 12:10:12 +02:00
2026-10-26 16:06:55 +02:00
2026-07-03 13:46:54 +00:00
2026-07-03 13:46:54 +00:00
2026-07-03 13:46:54 +00:00
2026-07-03 13:46:54 +00:00
2026-07-03 13:46:54 +00:00
2026-09-28 20:53:46 +03:00
2026-07-03 13:46:54 +00:00
2026-07-03 13:46:54 +00:00
2026-09-28 19:43:55 +03:00
2026-07-03 13:46:54 +00:00
2026-09-23 17:53:23 +03:00

3dealer

Storefront for 3dealer.gr: Laravel 12 + Lunar PHP (headless), on top of boboko/core. Front-end conventions are in CLAUDE.md.

Scheduled jobs

These run in the scheduler container (php artisan schedule:work).

Command When What it does
custom-fields:prune-uploads Daily, 04:00 Deletes custom-field photo uploads older than 24 h that no cart line or order line references.
lunar:search:index Daily, 03:00 Full product reindex. Registered by boboko/core.

Product custom fields

Admins can add custom fields to a product in the Lunar admin (the product's Custom Fields section, from boboko/core). The customer fills them in on the product page before adding the product to the cart. The answers are stored on the cart line (meta.custom_fields) and carried over to the order line.

Field type Storefront input Limit
Short text text input 255 characters
Long text textarea 2,000 characters
File upload photo upload JPG, PNG, WEBP, HEIC/HEIF, up to 10 MB
  • Photos upload as soon as they're picked. They go to POST /{locale}/custom-field-uploads, which is limited to 20 per minute per client. They're stored on the private local disk under storage/app/private/custom-field-uploads/. Only an encrypted reference is sent with add-to-cart. The allowed types and size are set in App\Http\Controllers\CustomFieldUploadController.
  • Photos are never public. The cart drawer, checkout summary and order confirmation link to a photo through a signed URL that expires after 2 hours.
  • Emails show text answers only, never photos.
  • Photos are cleaned up automatically. Photos never added to a cart are deleted by custom-fields:prune-uploads (see above). A photo on a cart line is kept as long as that cart line exists, and a photo on an order is kept indefinitely.
  • Products with custom fields can't be quick-added. On product cards, the "add to cart" button becomes a link to the product page.
  • Field labels are entered once in the admin and aren't translated, so they appear as entered in both /el and /en.
S
Description
No description provided
Readme
20 MiB
0 Stars 3 Watchers 0 Forks
Languages
Blade 40%
PHP 37.2%
JavaScript 10.8%
CSS 6.9%
Shell 4%
Other 1.1%