Deployment and Maintenance
This is the maintenance record for the small private playtest. It intentionally documents the pieces that are easy to forget between releases.
Cloudflare Production
Cloudflare is now the primary small-beta host. Netlify remains the rollback site for one release cycle.
- Live game: greenhouse-notes-playtest.pages.dev
- Current production game:
0.10.0-beta.19from commit94eac54; Cloudflare deployment previewdda9a18e. It removes repeated pot status elements and compacts the grid around a full-width selected tile. - Pages project:
greenhouse-notes-playtest - D1 database:
greenhouse-notes-feedback - Published directory:
prototype
The replacement uses Cloudflare Pages plus a small D1 feedback database:
- Players open a public
pages.devURL without creating an account. - The static game remains in
prototype; saves still stay in each browser undergreenhouse-notes-prototype-v1. functions/api/feedback.jsaccepts the in-game feedback form at/api/feedback.migrations/0001_feedback.sqldefines the private D1 inbox.wrangler.example.jsoncis safe to commit. The realwrangler.jsonccontains the account-specific database ID and is ignored.
First setup on a new account, after Cloudflare login:
npx --yes wrangler@latest d1 create greenhouse-notes-feedback
cp wrangler.example.jsonc wrangler.jsonc
Paste the returned database ID into wrangler.jsonc, then initialize and deploy:
npx --yes wrangler@latest d1 migrations apply greenhouse-notes-feedback --remote
npx --yes wrangler@latest pages deploy prototype --project-name greenhouse-notes-playtest
Because this project has a functions directory, release it with Wrangler rather than dashboard drag-and-drop. Run the command from the repository root so Pages sees both the static folder and the function.
Read recent feedback without exposing it in the game:
npx --yes wrangler@latest d1 execute greenhouse-notes-feedback --remote --command "SELECT created_at, nickname, target, category, comment, version, context FROM feedback ORDER BY created_at DESC LIMIT 50"
Before sharing each release, verify the game in a signed-out browser, submit one [QA TEST] report after feedback changes, confirm it appears in D1, and check phone plus desktop layouts. Keep the Netlify site intact through the first Cloudflare release cycle as rollback.
Dev Garden (Design/Docs Site)
The dev/ folder — the generated dashboard plus every doc page under dev/docs/ — is published as its own Cloudflare Pages project, separate from the player-facing game.
- Live: greenhouse-notes-devgarden.pages.dev
- Pages project:
greenhouse-notes-devgarden - Published directory:
dev(notprototype) - Purpose: sharing design notes and dev log with a trusted collaborator, read-only. Unlisted by URL, same privacy model as the game itself — not access-controlled.
- This is a manual snapshot, not part of the routine release flow. After editing any
notes/*.mdordesign/*.mdfile, rebuild the reading pages and redeploy this site separately from the game:
node dev/build-docs.cjs
npx --yes wrangler@latest pages deploy dev --project-name greenhouse-notes-devgarden
Legacy Netlify Production
- Live game: greenhouse-notes-playtest.netlify.app
- Private source: rubbishbean/greenhouse-notes
- Git branch:
main - Netlify project:
greenhouse-notes-playtest - Netlify site ID:
e5930aff-4652-4c0d-b27a-f186886d503f - Published directory:
prototype - Feedback form:
playtest-feedback
The live game is public to anyone with the URL and requires no player account. The GitHub repository remains private. Do not place design notes, test fixtures, or the Dev Garden inside the published prototype directory.
How The Pieces Fit
- GitHub is the private source history.
- Netlify serves only the static files in
prototype, as configured bynetlify.toml. - The game save stays in each player's browser under
greenhouse-notes-prototype-v1. - Feedback is separate from saves. Netlify Forms stores submissions for
playtest-feedbackin the project dashboard. .netlify/state.jsonlinks this checkout to the Netlify project, but.netlify/is intentionally ignored by Git. A new machine must link the site again.
No login, cloud save, or analytics service is active on the legacy release. Its feedback remains in Netlify Forms.
Current Production Build
Production is on 0.9.2-beta.1, released from commit 63b69e1 (Netlify deploy 6a7bc4cd366dd23fc1cd62ba). This release adds the sequential greenhouse reward route, save-aware research projects, cornflower, permanent irrigation and biological-control studies, the local tester console, explicit Spring Cup invitation, accumulated stall and workspace stability work, a mobile bottom-navigation fix, and clearer stem-based order valuation with a stronger first-order premium. See notes/dev-log.md (2026-08-11) and design/greenhouse-depth-roadmap.md for details.
In addition to the existing Spring Cup, market, wheel, automation, and hydrangea systems, it contains:
- the visible four-step watering and soil-automation catalog;
- the three-wave post-Cup flower market with held sale scenes and explicit wave advancement;
- optional event preparation spending and net-cash reporting;
- the bounded flower-market lucky wheel with one free draw, two optional paid draws, exact odds, and persistent borage pity;
- a large wheel close-up and saved prize reveal that cannot be skipped or rerolled by refresh;
- wheel-limited borage and a one-order double-payout voucher;
- post-tank wheel protection that converts the obsolete dripper result into a maintenance box;
- repeatable demand for blue, purple, and pink hydrangeas;
- contextual Spring Cup soil selection for hydrangeas, including inventory use and safe refunds;
- explicit mobile seed-choice counts and a pot-first targeted planting route;
- selected-bed irrigation routing plus visible ordinary, acidic, and alkaline soil profiles;
- pot-local mobile soil purchasing and application instead of a permanent full-page soil surface;
- exact order material deficits and an event-only main-greenhouse pause;
- named
种子库and温室商店destinations with restrained equipment and permanent-upgrade notices; - pot action bars without the misleading permanent watering-shop shortcut;
- a compact mobile selected-bed action dock with optional expanded detail;
- persistent mobile pause and resume in the bottom navigation;
- inventory-derived planting fallback when the selected seed is exhausted;
- full soil-profile borders and visually separated time controls;
- save migration for interrupted market results, unacknowledged wheel prizes, and earlier automation fields.
Release gate:
- Both smoke suites pass.
- Documentation pages rebuild and validate.
- Responsive production checks pass at 390×844 and 1280×720 without horizontal overflow.
- Existing saves and new event presentation states have migration coverage.
- Creator approves the held sale scenes, wheel close-up, and prize reveal for small-beta testing.
- Push the candidate commits to the private GitHub repository.
- Deploy to Netlify and verify the account-free live path and feedback form.
Netlify production deploy: 6a7587919e5cef52f23bfd02. Production loaded 0.8.4-beta.2 without an account gate. Direct production-file checks confirmed the seed fallback, complete soil-border treatment, and separated pause styles.
Current Release State
Private GitHub and Netlify production are on 0.8.4-beta.2 from commit 1b93644. This patch removes the exhausted-selection planting dead end and strengthens soil and time-control recognition.
Release verification:
- Both smoke suites pass.
- Documentation pages rebuild and validate.
- Whitespace validation passes.
- Wheel lifecycle, no-submission recovery, payments, prize application, order voucher, pity, and save migration are covered.
- Creator approves the integrated Spring Cup presentation for deployment.
- Production serves the expected app version with no account gate.
- Production passes desktop and phone-width overflow checks with no console warnings or errors.
The next evidence should come from the small beta group: whether held market results clarify pricing, whether the wheel now creates a memorable peak, and whether optional paid draws remain restrained.
Local mobile candidate gate:
- Fresh saves expose both starter species without requiring the full seed panel to be visible.
- Pot-first selection plants the chosen species into the intended bed.
- Automated checks cover seed discovery copy, targeted planting, irrigation routing, and soil-profile labels.
- Desktop browser inspection passes without console warnings or errors.
- Creator approved publishing the focused mobile UX experiment.
- GitHub
mainand Netlify production received the candidate. - Production serves the expected app version, mobile entry copy, and feedback form.
- Creator checks the revised controls at phone width and records whether non-mint seeds are now self-evident.
- Run one fresh ten-minute playtest before changing growth, water, or freshness timing.
Release-specific gate:
- Existing dripper rewards remain unchanged before the central tank.
- After the central tank, the same 8% slot resolves to a maintenance box instead of dead inventory.
- Blue, purple, and pink hydrangea each have a visible repeatable order.
- Event hydrangea soil selection, flower-color capture, specialist difficulty credit, product refunds, and old-save defaults have automated coverage.
- Creator approved direct deployment for small-beta playtesting.
- GitHub
mainand Netlify production received the candidate. - Production serves the expected version and feedback form.
- Collect beta feedback on whether the color routes and event-soil choice are legible without explanation.
Routine Release
From the repository root:
- Update
APP_VERSIONnear the top ofprototype/game.jsfor a player-facing release. - If Markdown documentation changed, rebuild the readable Dev Garden pages:
node dev/build-docs.cjs
- Run both smoke suites and the whitespace check:
node prototype/smoke-test.cjs
node tests/smoke-test.cjs
git diff --check
- Review the intended files, commit them, and push
mainto the private GitHub repository. - Deploy the tested
prototypedirectory to the linked production site:
npx --yes netlify-cli@latest deploy --prod --dir prototype
- Open the live URL in a signed-out or private browser window. Confirm the page loads without authentication, planting works, the layout does not scroll sideways on a phone-sized viewport, and the console has no errors.
- Submit one clearly labeled
[QA TEST]feedback item after any form change, then confirm it appears under NetlifyForms->playtest-feedback.
Do not deploy first and commit later. The Git commit should identify the source that was tested and released.
Local Preview
Use the project preview server instead of Python's generic static server:
node dev/local-preview.cjs
It binds only to 127.0.0.1:4174, preserving the existing browser save origin, and sends no-store headers for every file. An ordinary browser refresh therefore reads the current HTML, CSS, and JavaScript without clearing Chrome data or losing the local save.
Linking A New Machine
Install or invoke the Netlify CLI, authenticate as the owner of the existing project, then link this checkout by site ID:
npx --yes netlify-cli@latest login
npx --yes netlify-cli@latest link --id e5930aff-4652-4c0d-b27a-f186886d503f
Do not create a second Netlify project for routine maintenance. A successful link recreates the ignored .netlify/state.json file locally.
Feedback Inbox
Open the Netlify project dashboard, choose Forms, then playtest-feedback. Each report currently includes:
- feature target;
- category and written comment;
- optional nickname;
- app version;
- tester ID stored in that browser;
- viewport and coarse progression context.
The game does not intentionally attach email or a full save. Netlify records submission IP and browser identification as part of operating the form service, and the feedback sheet discloses this.
If a form submission fails, the browser keeps up to 30 reports in a local greenhouse-feedback-queue-v1 queue. This queue is only a fallback record on that same device; it is not currently retried automatically or visible to the developer.
Save Compatibility
The stable save key is greenhouse-notes-prototype-v1. Do not rename it merely because the app version changes; renaming it makes existing players appear to lose progress.
When state fields change:
- Give new fields defaults in
defaultState. - Extend
normalizeStateor its focused migration helpers so old saves receive those defaults. - Add a smoke test that loads the old shape and checks the migrated result.
- Test an existing browser save before production deployment.
The reset button deliberately erases only this game's local save on the current browser.
Rollback
For an urgent production problem, open the Netlify project's Deploys page and publish the last known-good deploy. This restores the static game files quickly but does not rewrite Git history or alter players' local saves.
After rollback, fix the source on main, increment the app version, rerun the checks, commit, push, and deploy normally. Avoid force-pushing or resetting shared history.
Configuration Notes
netlify.tomlsetsprototypeas the publish directory.- HTML, JavaScript, and CSS use revalidation headers so testers receive updates without a long stale cache.
- Camera, microphone, and geolocation are disabled through response headers.
- Keep the production visibility public while no-login access is a hard requirement.
- Keep form detection enabled in Netlify. The static form declaration in
prototype/index.htmlmust retainname="playtest-feedback",data-netlify="true", and its hiddenform-namefield.
Release Record
Record meaningful releases in notes/dev-log.md with the app version, commit, deployment result, and important QA coverage. Durable hosting or privacy decisions also belong in notes/decision-log.md.