Skip to content

Latest commit

 

History

History
109 lines (80 loc) · 3.54 KB

File metadata and controls

109 lines (80 loc) · 3.54 KB
title Development
order 2
tags
vscode
zed
podman
devcontainer
boost
ai

Development Setup

What you need

Setup

cd ~/projects
git clone git@github.com:francoism90/stry.git
cd stry
composer install
cp .env.example .env
php artisan key:generate

Pick one preset for the app image, then generate and install it together with proxy (see Podman Quadlet for the full service list):

  • development — mounts your working copy into the container live, so edits show up instantly. Use this day to day.
  • frankenphp-octane — the same image production uses, code baked in. Use this to test a production-style build locally.
php artisan podman:setup --preset=development --preset=proxy
# or: --preset=frankenphp-octane --preset=proxy

lpod install development/app.quadlets --replace
lpod install development/pgsql.quadlets --replace
# ...and so on for every service (see podman.md)

Tip

Set PODMAN_DEFAULT_PRESETS in .env (comma-separated, e.g. PODMAN_DEFAULT_PRESETS=development,s3,devcontainer,proxy) to skip passing --preset on every podman:setup run.

Set APP_ENV=local/APP_DEBUG=true/PWA_ENABLED=false (and any other local overrides) before storing them with lpod stry secrets.

Once the containers are up, install dependencies and seed data:

lpod stry shell
composer install
php artisan storage:link
php artisan migrate --seed
php artisan scout:sync
pnpm install

Run the Vite dev server from the host:

pnpm dev

VS Code Dev Containers

The devcontainer preset builds a dedicated image for the Dev Containers extension. With stry already running:

code ~/projects/stry

.devcontainer/devcontainer.json connects to the systemd-stry network and gives you PHP IntelliSense, debugging, and an integrated terminal.

Laravel IDE Helper

lpod stry artisan ide-helper:generate
lpod stry artisan ide-helper:meta
lpod stry artisan ide-helper:models --nowrite

AI-assisted development

Laravel Boost is wired up as an MCP server — in VS Code, open the Command Palette (Ctrl+Shift+P/Cmd+Shift+P) → "MCP: List Servers" → start laravel-boost.

Testing & code quality

lpod stry artisan test
lpod stry artisan test --filter=testMethodName
lpod stry bin pint
lpod stry bin larastan

Troubleshooting

  • Container won't startjournalctl --user -u stry -f; check for a missing/invalid stry-env secret or a port conflict (8000, 5173, 6001).
  • Permission issueschown -R 1000:1000 ~/projects/stry/storage (match your PODMAN_QUADLET_UID/GID if you changed them).
  • Assets not compilingrm -rf bootstrap/ssr && lpod stry npm run build.
  • Tests fail with could not translate host name "systemd-stry-pgsql" — you're running php artisan test directly on the host instead of inside the container network. Run lpod stry up first, then use lpod stry artisan test.

Next steps